We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
A mappable type is something that implemets __map__(self, f). A chainable type is something that implements __chain__(self, f).
mappable
__map__(self, f)
chainable
__chain__(self, f)
A type T that implements both can be used in do expressions as
T
do
fullname = do user_id('sad') as uid, first_name(uid) as first, last_name(uid) as last in f'{first} {last}'
Which will translate to
fullname = user_id('sad').__chain__(lambda uid: first_name(uid).__chain__(lambda first: last_name(uid).__map__(lambda last: f'{first} {last}')))
The text was updated successfully, but these errors were encountered:
No branches or pull requests
A
mappable
type is something that implemets__map__(self, f)
.A
chainable
type is something that implements__chain__(self, f)
.A type
T
that implements both can be used indo
expressions asWhich will translate to
The text was updated successfully, but these errors were encountered: