Commit Graph

26 Commits

Author SHA1 Message Date
Georges Dupéron
2d866bec01 Merge Racket ≤ 6.11 and Racket ≥ 6.12, using version-case (part 2: add old 6.11 files) 2018-03-26 01:10:20 +02:00
Georges Dupéron
3083001da9 Merge Racket ≤ 6.11 and Racket ≥ 6.12, using version-case (part 1: rename 6.12 files) 2018-03-25 23:58:43 +02:00
Ryan Culpepper
bf47b22091 syntax/parse: make undo cooperate with ~commit and ~! (cut) 2018-01-18 16:59:26 +01:00
Ryan Culpepper
9180a7dd19 syntax/parse template: add datum-template 2018-01-18 16:59:26 +01:00
Ryan Culpepper
bbde8031a9 syntax/parse template: move quasitemplate support to pre-pass
Note: quasisyntax has a bug: #`(... (1 2 #,@(list 3) 4)).
Within an escape, no way to express splicing desugaring.
So add a private variant of ?@ that is interpreted even escaped.
2018-01-18 16:59:26 +01:00
Ryan Culpepper
30eb04cf43 syntax/parse template: separate guide for re-syntax
Make datum->syntax explicit in guide rather than combined with
constructors like t-cons/x and t-dots (conditional).
This will make datum support easier, later.
For now, it makes it easier to do relocate correctly.

Also, make t-metafun, h-splice inlinable.
2018-01-18 16:59:26 +01:00
Ryan Culpepper
1f58e97282 syntax/parse template: add simple ellipsis special case 2018-01-18 16:59:26 +01:00
Ryan Culpepper
5eac499ec4 syntax/parse template: compile = datum->syntax
Change guide reps to coincide with expressions for template compilation.
2018-01-18 16:59:26 +01:00
Ryan Culpepper
1e0eb983a9 syntax/parse template: reorganize code, update comments 2018-01-18 16:59:26 +01:00
Ryan Culpepper
f8e01d52c6 syntax/parse template: encourage inlining of template combinators
With inlining, the optimizer can turn templates into mostly
first-order code.
2018-01-18 16:59:26 +01:00
Ryan Culpepper
034cde0a97 syntax/parse template: track syntax vs non-syntax pairs in template
Allows generation of more specialized code (hopefully smaller
and faster).

Also clean up some other guide reps.
2018-01-18 16:59:26 +01:00
Ryan Culpepper
a827322128 syntax/parse template: change run-time strategy
Instead of doing run-time interpretation of a "guide" tree,
generate code for procedure (using stx -> stx combinators).
2018-01-18 16:59:10 +01:00
Ryan Culpepper
1795b7af5f syntax/parse template: remove syntax-property handling
Since template was written, Racket has added a notion of preserved
syntax properties.
2018-01-18 15:01:28 +01:00
Georges Dupéron
6ac55c8e72 Applied changes requested by @rmculpepper for PR #1587 2018-01-18 14:55:58 +01:00
Georges Dupéron
21ee81c841 Require auto-syntax-e in residual. Provide template-metafunction? 2017-02-03 10:17:55 +01:00
Georges Dupéron
25ed9ec068 Integrate auto-syntax-e, as this needs a deep modification in the syntax-mapping struct 2017-02-01 08:01:18 +01:00
Georges Dupéron
c259afbe61 Removed parse/private/keywords.rkt, to improve compatibility with the official syntax/parse (that file defines ~optional etc.) 2017-01-28 05:16:59 +01:00
Georges Dupéron
bff27464a9 Bugfix and tests for define/with-syntax 2017-01-28 05:16:58 +01:00
Georges Dupéron
ad27231d00 Support #:properties on all four of (quasi)template(/loc), instead of just template. 2017-01-28 05:16:57 +01:00
Georges Dupéron
de60a419e2 Cherry-pick PR #1514: Added a syntax-local-template-metafunction-introduce function, so that template metafunctions can be unhygienic if necessary. 2017-01-28 05:16:57 +01:00
Georges Dupéron
64edde1f2d Re-add syntax/parse/experimental/private/substitute, so that we can apply PR #1514 2017-01-28 05:16:56 +01:00
Georges Dupéron
5d2f8cc512 Partially reverted previous commit. 2017-01-28 05:16:51 +01:00
Georges Dupéron
29c90350b2 Failed attempt at making metafunctions from syntax/parse/experimental/template and stxparse-info/parse/experimental/template compatible. I can manage to extract the binding from syntax/parse/…, but it seems to recognize a different struct (e.g. as if they were struct instances from two different phases) 2017-01-28 05:16:50 +01:00
Georges Dupéron
5be04ef8fd Removed all structure definitions from the copy of syntax/parse, and used the ones definied in the official syntax/parse 2017-01-28 05:16:48 +01:00
Georges Dupéron
02a0d43d0d Changed syntax/parse module paths to stxparse-info/parse 2017-01-28 05:16:33 +01:00
Georges Dupéron
8d4f899aa3 Imported files from 28f1df4cff 2017-01-28 05:16:11 +01:00