[Webkit-unassigned] [Bug 96798] [V8] Binding: Implement EnforceRange IDL Attribute for long long conversions

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Sep 20 13:59:00 PDT 2012


https://bugs.webkit.org/show_bug.cgi?id=96798





--- Comment #4 from Joshua Bell <jsbell at chromium.org>  2012-09-20 13:59:30 PST ---
Huh, I'm a bit stumped.

This should be a matter of dumping the appropriate tests into V8Binding.h's toInt64 (and then refactoring), and having toInt64() call throwTypeError(). However, when this is done the exception is not caught/rethrown by the v8::TryCatch block in EXCEPTION_BLOCK, so the script never sees the exception. 

Maybe v8 change r11894 is to blame?

Calling throwTypeError() winds its way into api.cc's ThrowException which calls Isolate::ScheduleThrow(). That method calls into Isolate::Throw(), then immediately moves the exception from "pending" to "scheduled" and clears the pending exception. Tracing through, nothing causes the "scheduled" exception to be "promoted" back to pending before the TryCatch block concludes.

v8 r11894 monkeys with the contents of Isolate::ScheduleThrow, removing a call to PropagatePendingExceptionToExternalTryCatch() which seems to be needed. If I undo that change then throwTypeError() works as expected.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list