-
-
Notifications
You must be signed in to change notification settings - Fork 92
New issue
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
Support "local" functions in the Editor #4612
Comments
I misunderstood the issue, apologies. I thought we were talking about calling higher-order functions with stdlib functions. Anyway, this isn't currently supported in the language. I guess it should probably be supported? I'd prefer folks used real functions in general but it's undeniable that local functions have their place. So if we want this we'll need a semantics defined as well the interaction model (basically, a definition of what the AST would be, and what the interpreter would do. This is usually pretty simple, though we'll need to account for incompletes, errorrails and derrors). Note that |
needs to be reassessed for modern day; folded into #5239, will reference this doc when it comes up |
It's often useful to define and then use a function 'inline':
You can currently define a
Block
and use it like this, but the editor only allows you to use it in functions that explicitly request aBlock
such asList::map
(at least, as far as I can tell). For example, you can't currently do the following:The new version of the language (in the backend) currently supports this, but the Editor does not.
TODOs:
The text was updated successfully, but these errors were encountered: