Fix lexer rules wrt leading zeros.

This commit is contained in:
chriseth 2020-12-14 14:09:28 +01:00
parent aa042ccb87
commit 6fff408d82

View File

@ -33,7 +33,7 @@ Event: 'event';
External: 'external'; External: 'external';
Fallback: 'fallback'; Fallback: 'fallback';
False: 'false'; False: 'false';
Fixed: 'fixed' | ('fixed' [0-9]+ 'x' [0-9]+); Fixed: 'fixed' | ('fixed' [1-9][0-9]* 'x' [1-9][0-9]*);
From: 'from'; From: 'from';
/** /**
* Bytes types of fixed length. * Bytes types of fixed length.
@ -86,7 +86,7 @@ Struct: 'struct';
True: 'true'; True: 'true';
Try: 'try'; Try: 'try';
Type: 'type'; Type: 'type';
Ufixed: 'ufixed' | ('ufixed' [0-9]+ 'x' [0-9]+); Ufixed: 'ufixed' | ('ufixed' [1-9][0-9]+ 'x' [1-9][0-9]+);
/** /**
* Sized unsigned integer types. * Sized unsigned integer types.
* uint is an alias of uint256. * uint is an alias of uint256.