Created
October 19, 2011 02:34
-
-
Save danking/1297350 to your computer and use it in GitHub Desktop.
This file contains 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
deref ::= id LBRACK num RBRACK | |
| id DOT id | |
| id DOT foo | |
id . LBRACK num RBRACK | |
id . DOT id | |
id . DOT foo | |
id DOT . id | |
id DOT . foo | |
. id LBRACK num RBRACK | |
. id DOT id | |
. id DOT foo | |
id DOT id . | |
id . LBRACK num RBRACK | |
id . DOT id | |
id . DOT foo | |
f[1].d[2] | |
Should parse to: | |
(deref/recurse | |
(deref/array (id f) LBRACK 1 RBRACK) | |
DOT | |
(deref/array (id d) LBRACK 2 RBRACK)) | |
not | |
(deref/recurse | |
(deref/array (id f) LBRACK 1 RBRACK) | |
DOT | |
(id d)) | |
followed by an error |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment