diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2021-05-06 06:33:38 -0700 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2021-05-06 06:33:38 -0700 |
commit | 4c6c110dfc3f10777fb7c9334c054d3407358af0 (patch) | |
tree | f0db3571f64f13be3553c391287907490709ff69 /tests/012 | |
parent | 94a855ee63bc2fc63a16e882eee1453877bf0bbc (diff) | |
download | txr-4c6c110dfc3f10777fb7c9334c054d3407358af0.tar.gz txr-4c6c110dfc3f10777fb7c9334c054d3407358af0.tar.bz2 txr-4c6c110dfc3f10777fb7c9334c054d3407358af0.zip |
parser: #; tests and bugfixes.
This is motivated by the recent crash regression in the #;
comment out mechanism. The parser doesn't have adequate
coverage in the test suite.
* tests/012/syntax.tl: New file, for testing syntax.
A problem was found #;.expr did not work inside a list,
only at top level. It required a space before the dot.
* parser.y (listacc): A couple of productions to handle
hash-semicolon immediately followed by a dot without
any whitespace, and then by an expression.
* y.tab.c.shipped: Regenerated.
Diffstat (limited to 'tests/012')
-rw-r--r-- | tests/012/syntax.tl | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/tests/012/syntax.tl b/tests/012/syntax.tl new file mode 100644 index 00000000..6b6f331a --- /dev/null +++ b/tests/012/syntax.tl @@ -0,0 +1,20 @@ +(load "../common") + +#;(commented out list) +#;3.14 +#;abc +#;.foo +#; .foo +#;a.b + +'(#;.foo) +'(#; .foo) + +(test + #;(commented out list) + #;3.14 + #;abc + #;.foo + #; .foo + #;a.b + 42 42) |