Changeset 29812 in webkit for trunk/JavaScriptCore/kjs


Ignore:
Timestamp:
Jan 26, 2008, 4:40:59 PM (17 years ago)
Author:
[email protected]
Message:

Fix Bug 17018: Incorrect code generated from Function.toString for get/setters in object literals

Reviewed by Darin.

Don't quote getter and setter names during output, as that is simply wrong.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/kjs/nodes2string.cpp

    r29809 r29812  
    381381            const FuncExprNode* func = static_cast<const FuncExprNode*>(assign.get());
    382382            if (type == Getter)
    383                 s << "get \"";
     383                s << "get ";
    384384            else
    385                 s << "set \"";
     385                s << "set ";
    386386            s << escapeStringForPrettyPrinting(name().ustring())
    387                 << "\"(" << func->param << ')' << func->body;
     387                << "(" << func->param << ')' << func->body;
    388388            break;
    389389        }
Note: See TracChangeset for help on using the changeset viewer.