[webkit-reviews] review requested: [Bug 53705] Viewport parsing no longer accepts "1.0; " value as valid. : [Attachment 83612] [PATCH] Add didReadNumber to see if toFloat / toDecimal to clarify if "ok" means garbage at end

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Feb 23 23:39:28 PST 2011


Joseph Pecoraro <joepeck at webkit.org> has asked	for review:
Bug 53705: Viewport parsing no longer accepts "1.0;" value as valid.
https://bugs.webkit.org/show_bug.cgi?id=53705

Attachment 83612: [PATCH] Add didReadNumber to see if toFloat / toDecimal to
clarify if "ok" means garbage at end
https://bugs.webkit.org/attachment.cgi?id=83612&action=review

------- Additional Comments from Joseph Pecoraro <joepeck at webkit.org>
I might as well do this right!

Much cleaner from the Viewport side of things. "ok" is false if there was any
error, and didReadNumber is true is there was ever a numeric value parsed.

Valid values also include scientific notation, so "1e3" is valid for 100.
I tested this with a bunch of numbers and prefixes +1, -1, .5, etc, and
it looked good.


More information about the webkit-reviews mailing list