Skip to content

Commit

Permalink
[fix] Json parser: proper handle of floats between -1 and 0
Browse files Browse the repository at this point in the history
  • Loading branch information
BourgerieQuentin authored and cedricss committed Nov 21, 2011
1 parent ff0f481 commit 6b295a9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libbase/jsonLex.ml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ let regexp t_blank = [' ' '\t' '\n' '\r']

let regexp t_digit = ['0'-'9']
let regexp t_digits = t_digit+
let regexp t_int = '0'| '-'? ['1'-'9'] t_digit*
let regexp t_int = '0'| '-''0' | '-'? ['1'-'9'] t_digit*
let regexp t_frac = "." t_digits
let regexp t_e = ("e"|"E") ("+"|"-")?
let regexp t_exp = t_e t_digits
Expand Down

0 comments on commit 6b295a9

Please sign in to comment.