RESOLVED FIXED 159500
[JSC] Unify how we throw TypeError from C++
https://bugs.webkit.org/show_bug.cgi?id=159500
Summary [JSC] Unify how we throw TypeError from C++
Benjamin Poulain
Reported 2016-07-06 18:23:07 PDT
[JSC] Unify how we throw TypeError from C++
Attachments
Patch (92.25 KB, patch)
2016-07-06 18:37 PDT, Benjamin Poulain
saam: review+
Benjamin Poulain
Comment 1 2016-07-06 18:37:39 PDT
Saam Barati
Comment 2 2016-07-06 18:59:40 PDT
Comment on attachment 282980 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=282980&action=review r=me with comments > Source/JavaScriptCore/ChangeLog:8 > + Throwing a TypeError is a uncommon case. We should minimize the impact "a" => "an" > Source/JavaScriptCore/ChangeLog:17 > + On x86_64, this reduces the __TEXT__ segment by 29kb. nice! > Source/JavaScriptCore/runtime/Error.h:87 > +inline EncodedJSValue throwVMTypeError(ExecState* exec, ASCIILiteral errorMessage) { return JSValue::encode(throwTypeError(exec, errorMessage)); } It's funny that "...VM..Error" just means that we return an EncodedJSValue. I wish we had a better name > Source/JavaScriptCore/runtime/JSTypedArrayViewPrototype.cpp:61 > + return throwVMTypeError(exec, \ Style: This "\" should be aligned with the other "\"
Benjamin Poulain
Comment 3 2016-07-06 20:13:14 PDT
Note You need to log in before you can comment on or make changes to this bug.