Changeset 34075 in webkit for trunk/JavaScriptCore/VM/Machine.cpp


Ignore:
Timestamp:
May 23, 2008, 7:23:23 AM (17 years ago)
Author:
[email protected]
Message:

SQUIRRELFISH: JavaScript error messages are missing informative text

Reviewed by Anders

Partial fix.
Tidy up error messages, makes a couple of them provide slightly more info.
Inexplicably leads to a 1% SunSpider Progression.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/VM/Machine.cpp

    r34069 r34075  
    430430}
    431431
    432 static NEVER_INLINE bool isNotObject(ExecState* exec, const Instruction*, CodeBlock*, JSValue* value, JSValue*& exceptionData)
     432static NEVER_INLINE bool isNotObject(ExecState* exec, bool forInstanceOf, CodeBlock*, JSValue* value, JSValue*& exceptionData)
    433433{
    434434    if (value->isObject())
    435435        return false;
    436     exceptionData = createNotAnObjectError(exec, value, 0);
     436    exceptionData = createInvalidParamError(exec, forInstanceOf ? "instanceof" : "in" , value);
    437437    return true;
    438438}
Note: See TracChangeset for help on using the changeset viewer.