forked from ceridwen/macropy
-
Notifications
You must be signed in to change notification settings - Fork 4
Open
Description
On some occasions, being able to pass named arguments to macros would be useful.
Use case, related to the multilambda macro in unpythonic (rackety lambda with implicit begin, for Python):
from multilambda import macros, λ
myadd = λ(x, y)[print(x, y), x + y]
assert myadd(2, 3) == 5
echo = λ(x='hi there')[print(x), x] # doesn't work, needs named arg support(Usage, implementation.)
For the same use case, *args and **kwargs support would be really nice. :)
Thoughts?
[edit] update link.
[edit2] these links are now obsolete; the silly λ macro has been removed.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels