Ignore:
Timestamp:
Apr 5, 2016, 4:50:34 PM (9 years ago)
Author:
Ryan Haddad
Message:

Unreviewed, rolling out r199073.
https://bugs.webkit.org/show_bug.cgi?id=156261

This change broke internal Mac builds (Requested by ryanhaddad
on #webkit).

Reverted changeset:

"We should support the ability to do a non-effectful getById"
https://bugs.webkit.org/show_bug.cgi?id=156116
http://trac.webkit.org/changeset/199073

Patch by Commit Queue <[email protected]> on 2016-04-05

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/jsc.cpp

    r199076 r199084  
    2424
    2525#include "ArrayPrototype.h"
    26 #include "BuiltinExecutables.h"
    2726#include "ButterflyInlines.h"
    2827#include "BytecodeGenerator.h"
     
    3433#include "Exception.h"
    3534#include "ExceptionHelpers.h"
    36 #include "GetterSetter.h"
    3735#include "HeapProfiler.h"
    3836#include "HeapSnapshotBuilder.h"
     
    555553static EncodedJSValue JSC_HOST_CALL functionCreateImpureGetter(ExecState*);
    556554static EncodedJSValue JSC_HOST_CALL functionCreateCustomGetterObject(ExecState*);
    557 static EncodedJSValue JSC_HOST_CALL functionCreateBuiltin(ExecState*);
    558555static EncodedJSValue JSC_HOST_CALL functionSetImpureGetterDelegate(ExecState*);
    559556
     
    576573static EncodedJSValue JSC_HOST_CALL functionHeapSize(ExecState*);
    577574static EncodedJSValue JSC_HOST_CALL functionAddressOf(ExecState*);
    578 static EncodedJSValue JSC_HOST_CALL functionGetGetterSetter(ExecState*);
    579575#ifndef NDEBUG
    580576static EncodedJSValue JSC_HOST_CALL functionDumpCallFrame(ExecState*);
     
    748744        addFunction(vm, "gcHeapSize", functionHeapSize, 0);
    749745        addFunction(vm, "addressOf", functionAddressOf, 1);
    750         addFunction(vm, "getGetterSetter", functionGetGetterSetter, 2);
    751746#ifndef NDEBUG
    752747        addFunction(vm, "dumpCallFrame", functionDumpCallFrame, 0);
     
    798793        addFunction(vm, "createImpureGetter", functionCreateImpureGetter, 1);
    799794        addFunction(vm, "createCustomGetterObject", functionCreateCustomGetterObject, 0);
    800         addFunction(vm, "createBuiltin", functionCreateBuiltin, 2);
    801795        addFunction(vm, "setImpureGetterDelegate", functionSetImpureGetterDelegate, 2);
    802796
     
    13391333}
    13401334
    1341 static EncodedJSValue JSC_HOST_CALL functionGetGetterSetter(ExecState* exec)
    1342 {
    1343     JSValue value = exec->argument(0);
    1344     if (!value.isObject())
    1345         return JSValue::encode(jsUndefined());
    1346 
    1347     JSValue property = exec->argument(1);
    1348     if (!property.isString())
    1349         return JSValue::encode(jsUndefined());
    1350 
    1351     Identifier ident = Identifier::fromString(&exec->vm(), property.toString(exec)->value(exec));
    1352 
    1353     PropertySlot slot(value, PropertySlot::InternalMethodType::VMInquiry);
    1354     value.getPropertySlot(exec, ident, slot);
    1355 
    1356     JSValue result;
    1357     if (slot.isCacheableGetter())
    1358         result = slot.getterSetter();
    1359     else
    1360         result = jsNull();
    1361 
    1362     return JSValue::encode(result);
    1363 }
    1364 
    13651335EncodedJSValue JSC_HOST_CALL functionVersion(ExecState*)
    13661336{
     
    17501720        return JSValue::encode(exec->vm().throwException(exec, error));
    17511721    return JSValue::encode(jsUndefined());
    1752 }
    1753 
    1754 EncodedJSValue JSC_HOST_CALL functionCreateBuiltin(ExecState* exec)
    1755 {
    1756     if (exec->argumentCount() < 1 || !exec->argument(0).isString())
    1757         return JSValue::encode(jsUndefined());
    1758 
    1759     String functionText = exec->argument(0).toString(exec)->value(exec);
    1760     if (exec->hadException())
    1761         return JSValue::encode(JSValue());
    1762 
    1763     VM& vm = exec->vm();
    1764     const SourceCode& source = makeSource(functionText);
    1765     JSFunction* func = JSFunction::createBuiltinFunction(vm, BuiltinExecutables::createExecutable(vm, source, Identifier::fromString(&vm, "foo"), ConstructorKind::None, ConstructAbility::CannotConstruct)->link(vm, source), exec->lexicalGlobalObject());
    1766 
    1767     return JSValue::encode(func);
    17681722}
    17691723
Note: See TracChangeset for help on using the changeset viewer.