Re: Constructible Exceptions

Marcos Caceres:
> The use case for throwing custom WebIDL exceptions is to be able to
> implement WebIDL interfaces directly in JavaScript (when allowed by
> the presence of [Constructor])…. though my real use case is to be
> able to construct DOMExceptions in JS, I'll need to take that up with
> DOM4.

This is already possible, because exception interface objects are 
required to be function objects with a [[Call]] behaviour that 
constructs the exception.  So there is no need for [Constructor] on them.

Received on Saturday, 24 March 2012 00:56:53 UTC