Skip to content

Add support for syntax-case and vanilla macro#6

Open
wsxiaoys wants to merge 2 commits into
feeley:masterfrom
wsxiaoys:master
Open

Add support for syntax-case and vanilla macro#6
wsxiaoys wants to merge 2 commits into
feeley:masterfrom
wsxiaoys:master

Conversation

@wsxiaoys

Copy link
Copy Markdown

No description provided.

@wsxiaoys

Copy link
Copy Markdown
Author

@feeley I played with define-library a bit and figure out a way to make it work with syntax-case / macro.

Let me know if anything could be improved!

Thanks
Meng

@wsxiaoys

wsxiaoys commented Jan 3, 2017

Copy link
Copy Markdown
Author

kindly ping

@feeley

feeley commented Jan 5, 2017

Copy link
Copy Markdown
Owner

Hi. Can you explain how your code works? It seems to avoid preprocessing the macro definitions, in other words the syntax-rules and syntax-case forms are passed through without modification.

@wsxiaoys

wsxiaoys commented Jan 5, 2017

Copy link
Copy Markdown
Author

i added define-runtime-syntax for syntax-case / syntax. syntax-rules is already a runtime syntax.

(syntax-rules ...) -> (syn#syntax-rules-form-transformer ...) -> #'(##lambda (##src) (syn#apply-rules 'crules ##src))

@wsxiaoys

Copy link
Copy Markdown
Author

ping? you might run tests to ensure it's working

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants