Clarification on exceptions

Hi
I'm seeking a bit of clarification on exception handling in the CR draft 
of the spec.

When calling getCurrentPosition(), the spec says that the method should 
be aborted if certain arguments are incorrect.

However tests in the test suites expect an exception to be thrown, for 
example:

http://dev.w3.org/geo/api/test-suite/t?00027
http://dev.w3.org/geo/api/test-suite/t?00028
http://dev.w3.org/geo/api/test-suite/t?00131

Should the spec say that an exception should be thrown (or even what kind)?

I'll also note that each browser seems to throw a different kind of 
exception (using t?00027):

Opera:
PASS: expected exception Error: WRONG_ARGUMENTS_ERR

Chrome:
PASS: expected exception Error: TYPE_MISMATCH_ERR: DOM Exception 17

Firefox 4:
PASS: expected exception [Exception... "Not enough arguments 
[nsIDOMGeoGeolocation.getCurrentPosition]" nsresult: "0x80570001 
(NS_ERROR_XPC_NOT_ENOUGH_ARGS)" location: "JS frame :: 
http://dev.w3.org/geo/api/test-suite/t00027.js :: anonymous :: line 5" 
data: no]

Kind regards,
Marcos
-- 
Marcos Caceres
Opera Software

Received on Sunday, 26 September 2010 16:34:29 UTC