W3C home > Mailing lists > Public > www-style@w3.org > September 2012

Re: [css-variables] How to spec the OM for vars?

From: Boris Zbarsky <bzbarsky@MIT.EDU>
Date: Mon, 03 Sep 2012 20:47:31 -0400
Message-ID: <50454FA3.9050100@mit.edu>
To: Garrett Smith <dhtmlkitchen@gmail.com>
CC: www-style@w3.org
On 9/3/12 8:34 PM, Garrett Smith wrote:
> What happens when the little 'compatibility view' icon, conveniently
> located next to the 'reload' button, is clicked? What does IE8 do?

I don't know, but how common are web pages that work in IE8 but not in 
any other browser?

>> It's a definition of what "delete el.style.var.foo" does (though it can
>> also affect other things, like attempts to use Array.prototype.shift on
>> the object in some cases).  You can see the spec at
>> http://dev.w3.org/2006/webapi/WebIDL/#delete
>
> At a glance, it looks like it results in a boolean value

That's because the caller in the ES spec (which I pointed you to) 
expects a boolean return value.  Note that the return value of 
[[Delete]] is not the same thing as the return value of the delete operator.

>> I'm not sure why you're so incredulous about "attempt to redefine the
>> delete operator", by the way, given that Harmony proxies have a delete
>> trap that's designed to allow proxy implementors to do precisely that.
>>
> Redefining the result of the `delete` operator, as it has been for the
> last 13+ years, in CSSOM vars

No, it's "redefined" in ECMAScript.  Or more precisely, ECMAScript 
provides extension points for redefining it as needed.  See ECMA-357 
sections 9.1.1.3 and 9.2.1.3 for other specifications making use of 
these extension points.

Also note that even in ES-262 the delete operator does different things 
on different objects.  For example, see the custom [[Delete]] that 
arguments objects have in ECMA-262 section 10.6 (sorry, no subsection 
number for the relevant part of the spec because it's all flat in 10.6; 
you'll just have to search for "[[Delete]] internal method of an 
arguments object".

So I think your claim about "as it has been for the last 13+ years" is 
just wrong: the delete operator has done different things on different 
kinds of objects for a while already.

> so that it can result in a string value?

I have no idea what you're talking about here.

> Nevermind.

Willingly, as long as you stop making factually incorrect statements.  ;)

-Boris
Received on Tuesday, 4 September 2012 00:48:02 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:59 GMT