[whatwg] URL: URLQuery

Rick Waldron waldron.rick at gmail.com
Sat Dec 1 11:06:01 PST 2012


On Fri, Nov 30, 2012 at 1:29 PM, Tab Atkins Jr. <jackalmage at gmail.com>wrote:

> On Fri, Nov 30, 2012 at 10:02 AM, Alexandre Morgaut
> <Alexandre.Morgaut at 4d.com> wrote:
> >> Only feedback left is the return types of set(), append(), and delete().
> >
> > Maybe remove() would be better than delete() as delete is a reserved JS
> keyword ;-)
>
> Nope, it's contextually reserved.  You can use in places like a method
> name without a problem.
>

Correct.

For some background: the specification[0] rules that Identifiers are
IdentifierNames that are not a ReservedWord. A ReservedWord itself is
an IdentifierName that cannot be an Identifier; PropertyName is an
IdentifierName so it gets the same treatment, eg. var o = { function:
function() { return true; } }; o.function(); // true

I just checked and no browser's latest stable release has the bug that
would cause an exception to be thrown when a ReservedWord was used as a
PropertyName (which is great, because the last time I checked for this,
Safari 5.0.? did throw)


Rick

[0] http://es5.github.com/#x7.6



>
> ~TJ
>



More information about the whatwg mailing list