W3C home > Mailing lists > Public > public-script-coord@w3.org > July to September 2015

[Bug 28875] [EnforceRange] accepts an odd set of input values

From: <bugzilla@jessica.w3.org>
Date: Wed, 01 Jul 2015 20:42:53 +0000
To: public-script-coord@w3.org
Message-ID: <bug-28875-3890-ZjG8Grk3RP@http.www.w3.org/Bugs/Public/>

Boris Zbarsky <bzbarsky@mit.edu> changed:

           What    |Removed                     |Added
                 CC|                            |bzbarsky@mit.edu

--- Comment #1 from Boris Zbarsky <bzbarsky@mit.edu> ---
> Looking at uses: I see 3 existing uses in Blink, all in IndexedDB: 

shows uses in SubtleCrypto as well.

What exactly is the problem with the current behavior?  Assuming you plan to do
a coercion to number at all, you have to do it before checking range.  The only
other option would be to immediately throw if the passed-in thing is not a
Number value, right?  That would break things like passing "123" (e.g. out of
input.value) for cases where the callee wants a range-enforced integer.

You are receiving this mail because:
You are on the CC list for the bug.
Received on Wednesday, 1 July 2015 20:42:55 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 17:14:24 UTC