diff options
author | m8pple <dt10@imperial.ac.uk> | 2017-02-01 11:59:02 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-02-01 11:59:02 +0000 |
commit | b42d4b5940b28093d941c117ff376b556917c43e (patch) | |
tree | 79b7ccccd49ec2f22ffdf90baf6c176953e90e69 /1-lexer.md | |
parent | e44c3dcbf4d85315e7fffc7c3c0717293f40fb1b (diff) | |
download | Compiler-b42d4b5940b28093d941c117ff376b556917c43e.tar.gz Compiler-b42d4b5940b28093d941c117ff376b556917c43e.zip |
Fix bug in updated string literal notes. Thanks to @MK2020. Closes #8
Diffstat (limited to '1-lexer.md')
-rw-r--r-- | 1-lexer.md | 7 |
1 files changed, 3 insertions, 4 deletions
@@ -161,15 +161,14 @@ matter. There is some [ambiguity](#2) over the string literals, which might or might not include the quotes. _Both_ forms will be accepted as -value, so this: -Another session for a different lexer could be (preferred): +value, so another session for a different lexer could be (preferred): ```` $ cat wibble.c z="wibble" $ cat wibble.c | bin/c_lexer [ { "Class" : "Identifier", "Text": "z" }, { "Class" : "Operator", "Text": "=" }, - { "Class" : "StringLiteral", "Text": "z" } + { "Class" : "StringLiteral", "Text": "wibble" } ] ```` or @@ -178,7 +177,7 @@ or $ cat wibble.c | bin/c_lexer [ { "Class" : "Identifier", "Text": "z" }, { "Class" : "Operator", "Text": "=" }, - { "Class" : "StringLiteral", "Text": "\"z\"" } + { "Class" : "StringLiteral", "Text": "\"wibble\"" } ] ```` |