Improper parsing of numbers - leading zeroes should be disallowed

Description

Handling of numeric literals doesn't perform according to the JSON spec.

Example:

Both of these examples parse the number as 123. According to the spec, this should actually be an invalid number and throw an exception. NB this restriction does not seem to apply to a number in the exponent, so a number like 1e0003 should be parsed as 1000.0. We handle this case correctly now.

Environment

None

Activity

Show:
Alex Miller
4 days ago

Fixed via

import
July 30, 2015, 4:34 PM

Fix + Tests. Feedback welcome.

Fixed

Assignee

Unassigned

Reporter

import