Don't allow *s in strings that aren't escapes.

This commit is contained in:
Adam Sampson 2007-08-21 17:20:10 +00:00
parent 8a3edfd2e2
commit d28e945574

View File

@ -68,8 +68,8 @@ $hexDigit = [0-9 a-f A-F]
$escapeChar = [cnrts \" \' \* \n]
@escape = \* ( $escapeChar | \# $hexDigit $hexDigit )
@stringLiteral = \" ( @escape | [^\"] )* \"
@charLiteral = \' ( @escape | [^\'] ) \'
@stringLiteral = \" ( @escape | [^\"\*] )* \"
@charLiteral = \' ( @escape | [^\'\*] ) \'
-- Note that occam number literals don't include their signs -- if you say
-- "-3", then that's the operator "-" applied to the literal "3".