paul@390 | 1 | Consider attribute assignment observations, along with the possibility of class attribute
|
paul@390 | 2 | assignment.
|
paul@372 | 3 |
|
paul@376 | 4 | Local assignment detection plus frame re-use. Example: slice.__init__ calls
|
paul@376 | 5 | xrange.__init__ with the same arguments which are unchanged in xrange.__init__. There is
|
paul@376 | 6 | therefore no need to build a new frame for this call.
|
paul@376 | 7 |
|
paul@372 | 8 | Consider attribute usage observations being suspended inside blocks where AttributeError
|
paul@372 | 9 | may be caught (although this doesn't anticipate such exceptions being caught outside a
|
paul@372 | 10 | function altogether).
|
paul@372 | 11 |
|
paul@368 | 12 | Fix object table entries for attributes not provided by any known object, or provide an
|
paul@368 | 13 | error, potentially overridden by options. For example, the augmented assignment methods
|
paul@368 | 14 | are not supported by the built-in objects and thus the operator module functions cause
|
paul@372 | 15 | the compilation to fail. Alternatively, just supply the methods since something has to do
|
paul@372 | 16 | so in the builtins.
|
paul@368 | 17 |
|
paul@364 | 18 | Consider type deduction and its consequences where types belong to the same hierarchy
|
paul@364 | 19 | and where a guard could be generated for the most general type.
|
paul@364 | 20 |
|
paul@364 | 21 | Consider attribute merging where many attributes are just aliases for the same underlying
|
paul@364 | 22 | definition.
|
paul@364 | 23 |
|
paul@362 | 24 | Consider merging the InspectedModule.store tests with the scope conflict handling.
|
paul@362 | 25 |
|
paul@364 | 26 | Consider permitting multiple class alternatives where the attributes are all identical.
|
paul@364 | 27 |
|
paul@360 | 28 | Support class attribute positioning similar to instance attribute positioning, potentially
|
paul@360 | 29 | (for both) based on usage observations. For example, if __iter__ is used on two classes,
|
paul@360 | 30 | the class attribute could be exposed at a similar relative position to the class (and
|
paul@360 | 31 | potentially accessible using a LoadAttr-style instruction).
|
paul@360 | 32 |
|
paul@349 | 33 | Consider references to defaults as occurring only within the context of a particular
|
paul@349 | 34 | function, thus eliminating default value classes if such functions are not themselves
|
paul@349 | 35 | invoked.
|
paul@349 | 36 |
|
paul@343 | 37 | Consider labelling _scope on assignments and dealing with the assignment of removed
|
paul@343 | 38 | attributes, possibly removing the entire assignment, and distinguishing between such cases
|
paul@343 | 39 | and unknown names.
|
paul@343 | 40 |
|
paul@342 | 41 | Check name origin where multiple branches could yield multiple scope interpretations:
|
paul@342 | 42 |
|
paul@342 | 43 | ----
|
paul@342 | 44 | try:
|
paul@342 | 45 | set # built-in name
|
paul@342 | 46 | except NameError:
|
paul@342 | 47 | from sets import Set as set # local definition of name
|
paul@342 | 48 |
|
paul@342 | 49 | set # could be confused by the local definition at run-time
|
paul@342 | 50 | ----
|
paul@342 | 51 |
|
paul@332 | 52 | Support __init__ traversal (and other implicit names) more effectively.
|
paul@332 | 53 |
|
paul@332 | 54 | Check context_value initialisation (avoiding or handling None effectively).
|
paul@332 | 55 |
|
paul@342 | 56 | __getitem__ could be written in Python, using a native method only to access fragments.
|
paul@349 | 57 |
|
paul@342 | 58 | Consider better "macro" support where new expressions need to be generated and processed.
|
paul@342 | 59 |
|
paul@342 | 60 | **** Constant attribute users need not maintain usage since they are already resolved. ****
|
paul@342 | 61 |
|
paul@310 | 62 | Loop entry points should capture usage to update later assignments in the loop.
|
paul@310 | 63 | The continue and break statements should affect usage propagation.
|
paul@304 | 64 |
|
paul@304 | 65 | Consider handling CallFunc in micropython.inspect in order to produce instances of specific classes.
|
paul@304 | 66 | Then, consider adding support for guard removal/verification where known instances are involved.
|
paul@304 | 67 | Consider handling branches of values within namespaces in order to support more precise value usage.
|