Remove custom bindings for code with simple preconditions
https://bugs.webkit.org/show_bug.cgi?id=38313
Summary Remove custom bindings for code with simple preconditions
Adam Barth
Reported 2010-04-29 01:01:45 PDT
Remove custom bindings for code with simple preconditions
Attachments
Work in progress (72.32 KB, patch)
2010-04-29 01:02 PDT, Adam Barth
no flags
Adam Barth
Comment 1 2010-04-29 01:02:14 PDT
Created attachment 54679 [details] Work in progress
Adam Barth
Comment 2 2010-04-29 01:02:56 PDT
I'm not 100% happy with this patch yet. Also, I haven't done the V8 parts properly yet.
Yaar Schnitman
Comment 3 2010-04-29 09:52:00 PDT
Wouldn't it simplify things if these checks are pushed deeper from the bindings into webcore? I understand why this is hard when a method / getter returns a primitive.
Adam Barth
Comment 4 2010-04-29 12:11:17 PDT
There's a question of whether we're supposed to throw these errors before or after coercing the arguments. I'll study the feasibility of pushing these checks into WebCore.
Adam Barth
Comment 5 2010-04-29 14:21:27 PDT
A patch in that direction is available here: https://bugs.webkit.org/show_bug.cgi?id=38344
Yaar Schnitman
Comment 6 2010-04-29 14:36:36 PDT
As for NullIf for members that return primitives (e.g. double), we might need to change the spec.
Adam Barth
Comment 7 2010-04-29 15:43:40 PDT
Yeah. Maybe they should throw? It's unclear that null is a valid value for double.
Note You need to log in before you can comment on or make changes to this bug.