- From: Jonas Sicking <jonas@sicking.cc>
- Date: Fri, 31 Aug 2012 13:03:50 -0300
- To: Boris Zbarsky <bzbarsky@mit.edu>
- Cc: www-dom@w3.org
On Fri, Aug 31, 2012 at 12:26 PM, Boris Zbarsky <bzbarsky@mit.edu> wrote: > On 8/31/12 8:24 AM, Bjoern Hoehrmann wrote: >> >> Allowing this results in odd situations like `a != b` right >> after setting `a = b` > > > This is already all over the web platform. First of all, every case with > [PutForwards] (which is how one would implement the behavior in question). > An existing example: > > window.location = "http://something"; > alert(window.location); // alerts "object" > > Or even in the CSSOM: > > div.style.color = "red"; > div.style.color = "oh, you want equality?" > alert(div.style.color); // alerts "red" > > or in the DOM: > > div.innerHTML = "<span>foo" > alert(div.innerHTML); // alerts "<span>foo</span>" > > Just saying. If we really wanted to do this, implementing it in the web > platform would be pretty straightforward: toss [PutForwards=cssText] on the > .style attribute, and WebIDL will take care of the rest.... For what it's worth. This is the reason that I think that [PutsForwards] is a really bad idea. It makes the platform more complicated for relatively little gain. And so I think we should have left it as a document.location legacy quirk. I've so far always lost this argument though as it keeps being added to new APIs. / Jonas
Received on Friday, 31 August 2012 16:04:52 UTC