You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Right now only function aliases are supported via internal.utils.alias. Aliases for namespaces (database.integer aliased as database.i, database.entries aliased as database.exports, database.address as database.a, or database.type as database.t, etc.) are implemented by (straight-up) assigning the namespace to the target alias variable. This has negative effects with things such as help() since due to more than one variable being assigned for the same class, the documentation for the class is listed multiple times.
It'd be nice to do something similar to internal.utils.alias, but rather for namespaces so that way the help() for the namespace alias can simply be a reference to the real namespace. Then the reStructuredText generator in docs/docparse.py within the docs branch can be modified to reference the decorator to determine what aliases exist for a particular namespace.
The text was updated successfully, but these errors were encountered:
Currently as per #158, the research into temporal modules has resulted in a solution for this using a proxy class (that maintains no internal state) which can change depending on a backing object. Thus combining that with descriptors will allow making proper aliases for different namespaces.
Also per #158, the pattern matching part for multicased functions is currently being redesigned which should allow for better performance when identifying the right function definition for a namespace attribute.
The multicased function feature has been redesigned algorithmically. Although I don't think that having real-aliased namespaces is too important, this should definitely be worked on as it shouldn't be too much extra work.
Right now only function aliases are supported via
internal.utils.alias
. Aliases for namespaces (database.integer
aliased asdatabase.i
,database.entries
aliased asdatabase.exports
,database.address
asdatabase.a
, ordatabase.type
asdatabase.t
, etc.) are implemented by (straight-up) assigning the namespace to the target alias variable. This has negative effects with things such ashelp()
since due to more than one variable being assigned for the same class, the documentation for the class is listed multiple times.It'd be nice to do something similar to
internal.utils.alias
, but rather for namespaces so that way thehelp()
for the namespace alias can simply be a reference to the real namespace. Then the reStructuredText generator indocs/docparse.py
within thedocs
branch can be modified to reference the decorator to determine what aliases exist for a particular namespace.The text was updated successfully, but these errors were encountered: