- From: Bjoern Hoehrmann <derhoermi@gmx.net>
- Date: Sat, 03 Aug 2013 13:52:23 +0200
- To: bugzilla@jessica.w3.org
- Cc: public-script-coord@w3.org
* bugzilla@jessica.w3.org wrote: >--- Comment #15 from Cameron McCormack <cam@mcc.id.au> --- >I still disagree that you always want to swallow the exception from the >callback. I would say, in general, that if the function you're passing the >callback to is going to synchronously call your callback, then the exception >should propagate out. Like it does with Array.prototype.sort. But if the >callback is going to be invoked asynchronously, then obviously there's no >top-level JS stack frame to propagate it out to. That's a terrible analogy. The caller of `sort` is responsible for the behavior of the callback. With `dispatchEvent` there may be multiple independent entities responsible for the behavior of the listeners and the caller of `dispatchEvent` might not even be among them. -- Björn Höhrmann · mailto:bjoern@hoehrmann.de · http://bjoern.hoehrmann.de Am Badedeich 7 · Telefon: +49(0)160/4415681 · http://www.bjoernsworld.de 25899 Dagebüll · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/
Received on Saturday, 3 August 2013 11:52:43 UTC