Skip to content
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

Nested quasiquotes don't work #32

Closed
dido opened this issue Jan 22, 2012 · 5 comments
Closed

Nested quasiquotes don't work #32

dido opened this issue Jan 22, 2012 · 5 comments
Assignees

Comments

@dido
Copy link
Owner

@dido dido commented Jan 22, 2012

arc> (eval ``(+ 1 ,,@(list 2 3) 4))
Error: Unbound symbol: _unquote-splicing

Presumably we want the above form to evaluate to (+ 1 2 3 4) the way Common Lisp would, as opposed to the '(+ 1 2 4) that Scheme (erroneously) produces.

@ghost ghost assigned dido Jan 22, 2012
@akkartik
Copy link

@akkartik akkartik commented Apr 23, 2013

👍

Do you remember what scheme gave that result? On racket:

> ``(+ 1 ,,@(list 2 3) 4)
'`(+ 1 (unquote 2 3) 4)

(Wart gets it right :)

@dido
Copy link
Owner Author

@dido dido commented Apr 25, 2013

Off hand can't quite remember. I think it was an older version of Scheme48, as the present version I have installed right now (two computers and four OS reinstalls later) doesn't do it.

@dido dido closed this Apr 25, 2013
@dido dido reopened this Apr 25, 2013
@dido
Copy link
Owner Author

@dido dido commented Apr 26, 2013

(+ 1 2 4) is what current reference Arc does when presented with (eval ``(+ 1 ,,@(list 2 3) 4)). Not sure why it does that.

Found an old discussion on this very topic:

http://arclanguage.org/item?id=9962

Looks like the code linked to there might be the basis for Arcueid's new quasiquote algorithm.

@akkartik
Copy link

@akkartik akkartik commented Apr 26, 2013

Holy crap, you're right! Anarki is the same. I could swear this was fixed at some point. Perhaps on the arc2 branch?

@dido
Copy link
Owner Author

@dido dido commented Apr 29, 2013

Nested quasiquote behaviour now obeys Common Lisp semantics as of a2f07b0

@dido dido closed this Apr 29, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.