hughperman / pure-lang

Automatically exported from code.google.com/p/pure-lang
0 stars 0 forks source link

Glitches in the lexer #84

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
These affect lexer.ll.

- If the xdecl_bad_char and xusing_bad_char labels are reached from a rejected 
command prefix, the error message about an "invalid character" may be somewhat 
off the mark, since the prefix may well contain an entire command word. We 
should use better wording there, like "invalid token".

- The following will create a bad symbol because of the rule for ^<cmd>:

nonfix
^bla;

This is accepted without error message, and 'show -g *bla*' then reveals that 
this in fact creates the invalid symbol ^bla. To avoid this kind of mishap, the 
^<cmd> rule should strip off the non-prefix part of the bad command with 
yyless() before chaining to parse_op.

Original issue reported on code.google.com by aggraef@gmail.com on 16 Jul 2012 at 11:21

GoogleCodeExporter commented 8 years ago
This issue was closed by revision b110016c9049.

Original comment by aggraef@gmail.com on 15 Aug 2012 at 7:38