Permalink
Browse files

fix to number parsing

  • Loading branch information...
1 parent 52b696d commit dec3fff28619c719ee4454e52873ac482b6597bd @jbclements committed Mar 29, 2013
Showing with 5 additions and 1 deletion.
  1. +1 −1 Rust.g4
  2. +4 −0 tests.txt
View
2 Rust.g4
@@ -469,7 +469,7 @@ OTHER_BLOCK_COMMENT : '/*' (~[*] | ('*'+ ~[*/]))* '*'+ '/' -> skip ;
BINDIGIT : [0-1_] ;
DECDIGIT : [0-9_] ;
HEXDIGIT : [0-9a-fA-F_] ;
-INTLIT_TY : ('u'|'i') ('8'|'16'|'32'|'64') ;
+INTLIT_TY : ('u'|'i') ('8'|'16'|'32'|'64')? ;
LITFLOAT_EXP : [eE] [+-]? DECDIGIT+ ;
LITFLOAT_TY : 'f' ('32'|'64') ;
View
4 tests.txt
@@ -6,3 +6,7 @@
/*! ****/ */
(tts (tt (nondelim /*! ****/)) (tt (nondelim *)) (tt (nondelim /)))
+
+16u
+(tts (tt (nondelim 16u)))
+

0 comments on commit dec3fff

Please sign in to comment.