Improve and document 'capture'
This commit is contained in:
parent
b1f1edba94
commit
7a52377ae9
4 changed files with 71 additions and 3 deletions
|
|
@ -326,6 +326,7 @@ class Type:
|
|||
x = Type()
|
||||
y = Type()
|
||||
z = Type()
|
||||
def capture(self, attribute: Type, **kwargs) -> Callable[[], Type]: return transfer_attribute
|
||||
{(newline + ' ').join(map(lambda x: x.replace('(', '(self, '), filter(lambda x: x.startswith('def'), symbols)))}
|
||||
|
||||
{newline.join(map(type_symbol, Type.__subclasses__()))}
|
||||
|
|
|
|||
Reference in a new issue