-
Notifications
You must be signed in to change notification settings - Fork 756
Description
I believe the correct parsing of real numbers as specified by the railroad diagram is not implemented by the prose sections describing number parsing.
Specifically, it appears sections 4.3.12. Consume a number and 4.3.13. Convert a string to a number will allow "-E7" as a number.
This would conflict with the railroad diagram which requires something between sign and 'E'. It also seemingly conflicts with the spec's hyper-rigidity where "1.E1" is disallowed. (#3599)
(BTW: am I correct that that railroad diagram was copied from an older SVG spec?)
.
Once again I was trying to find the definition for SVG real numbers and the chain of refs led me to CSS Syntax. Specifically I was trying to find the 'rightness' of an emitted "9e-5" or "-1e-4".
I find section <number-token> under 4.1. Token Railroad Diagrams and say "yay, I'm right!"
Then I find section 4.3.12. Consume a number and am dismayed. Then I realized that spec was merely confusing and did allow for "9e-5". Then it seemed it was so loose as to allow for gibberish - no number at all!
I checked section 4.3.13. Convert a string to a number figuring it would restrict further. But like 4.3.12 so many of the parts are optional, there is little in the way of a minimal content required.
Was it intended to allow "E99" as a <number-token>?