Remove flag syntax - #192
Open
shawwn wants to merge 1 commit into
Open
Conversation
Owner
|
Hmmm. I'll let this one percolate. |
Contributor
Author
|
One benefit is that it frees : as a special character, the way that period
currently is. So something like this could have special meaning:
(get reader :read-string)
In fact, I could update BIND so that it preserves the existing lumen
semantics. That way you could still write
(let ((:pos :len :string) (stream “foo”))
...)
…On Sat, Sep 15, 2018 at 3:24 PM Scott Bell ***@***.***> wrote:
Hmmm. I'll let this one percolate.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#192 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AADo8MWblrZI4thAfht2DeZKP-PZtUM3ks5ubWH8gaJpZM4WZYz9>
.
|
Contributor
Author
I think it's worth getting rid of flag syntax, but messing with BIND is a bad idea. It introduces confusion and makes calling syntax inconsistent with LET bindings. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
If we remove flag syntax, we can use Lumen's reader to read most other
dialects of Lisp: Emacs Lisp, Common Lisp, etc. This makes it easier
to implement a compiler backend for them.
The loss of expressive power seems minimal compared to the gain in
flexibility.