Changeset 126397 in webkit


Ignore:
Timestamp:
Aug 22, 2012 11:54:26 PM (12 years ago)
Author:
haraken@chromium.org
Message:

Unreviewed, rolling out r126348.
http://trac.webkit.org/changeset/126348
https://bugs.webkit.org/show_bug.cgi?id=94588

We should use v8::String::NewSymbol() for symbols. See
https://bugs.webkit.org/show_bug.cgi?id=94574#c10 for more
details

  • bindings/scripts/CodeGeneratorV8.pm:

(GenerateNormalAttrGetter):
(GenerateNormalAttrSetter):
(GenerateNamedConstructorCallback):
(GenerateNonStandardFunction):
(GenerateImplementation):

  • bindings/scripts/test/V8/V8Float64Array.cpp:

(WebCore::ConfigureV8Float64ArrayTemplate):

  • bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:

(WebCore::ConfigureV8TestActiveDOMObjectTemplate):

  • bindings/scripts/test/V8/V8TestEventTarget.cpp:

(WebCore::ConfigureV8TestEventTargetTemplate):

  • bindings/scripts/test/V8/V8TestInterface.cpp:

(WebCore::ConfigureV8TestInterfaceTemplate):

  • bindings/scripts/test/V8/V8TestNamedConstructor.cpp:

(WebCore::V8TestNamedConstructorConstructor::GetTemplate):

  • bindings/scripts/test/V8/V8TestObj.cpp:

(WebCore::ConfigureV8TestObjTemplate):
(WebCore::V8TestObj::installPerContextProperties):

  • bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:

(WebCore::TestSerializedScriptValueInterfaceV8Internal::cachedValueAttrGetter):
(WebCore::TestSerializedScriptValueInterfaceV8Internal::cachedValueAttrSetter):
(WebCore::TestSerializedScriptValueInterfaceV8Internal::cachedReadonlyValueAttrGetter):

  • bindings/v8/V8Binding.h:

(WebCore):

Location:
trunk/Source/WebCore
Files:
10 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r126393 r126397  
     12012-08-22  Kentaro Hara  <haraken@chromium.org>
     2
     3        Unreviewed, rolling out r126348.
     4        http://trac.webkit.org/changeset/126348
     5        https://bugs.webkit.org/show_bug.cgi?id=94588
     6
     7        We should use v8::String::NewSymbol() for symbols. See
     8        https://bugs.webkit.org/show_bug.cgi?id=94574#c10 for more
     9        details
     10
     11        * bindings/scripts/CodeGeneratorV8.pm:
     12        (GenerateNormalAttrGetter):
     13        (GenerateNormalAttrSetter):
     14        (GenerateNamedConstructorCallback):
     15        (GenerateNonStandardFunction):
     16        (GenerateImplementation):
     17        * bindings/scripts/test/V8/V8Float64Array.cpp:
     18        (WebCore::ConfigureV8Float64ArrayTemplate):
     19        * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
     20        (WebCore::ConfigureV8TestActiveDOMObjectTemplate):
     21        * bindings/scripts/test/V8/V8TestEventTarget.cpp:
     22        (WebCore::ConfigureV8TestEventTargetTemplate):
     23        * bindings/scripts/test/V8/V8TestInterface.cpp:
     24        (WebCore::ConfigureV8TestInterfaceTemplate):
     25        * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
     26        (WebCore::V8TestNamedConstructorConstructor::GetTemplate):
     27        * bindings/scripts/test/V8/V8TestObj.cpp:
     28        (WebCore::ConfigureV8TestObjTemplate):
     29        (WebCore::V8TestObj::installPerContextProperties):
     30        * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
     31        (WebCore::TestSerializedScriptValueInterfaceV8Internal::cachedValueAttrGetter):
     32        (WebCore::TestSerializedScriptValueInterfaceV8Internal::cachedValueAttrSetter):
     33        (WebCore::TestSerializedScriptValueInterfaceV8Internal::cachedReadonlyValueAttrGetter):
     34        * bindings/v8/V8Binding.h:
     35        (WebCore):
     36
    1372012-08-22  Kentaro Hara  <haraken@chromium.org>
    238
  • trunk/Source/WebCore/bindings/scripts/CodeGeneratorV8.pm

    r126393 r126397  
    905905        if ($attribute->signature->type eq "SerializedScriptValue" && $attrExt->{"CachedAttribute"}) {
    906906            push(@implContentDecls, <<END);
    907     v8::Handle<v8::String> propertyName = v8String("${attrName}", info.GetIsolate());
     907    v8::Handle<v8::String> propertyName = v8::String::NewSymbol("${attrName}");
    908908    v8::Handle<v8::Value> value = info.Holder()->GetHiddenValue(propertyName);
    909909    if (!value.IsEmpty())
     
    12931293    if ($attribute->signature->type eq "SerializedScriptValue" && $attribute->signature->extendedAttributes->{"CachedAttribute"}) {
    12941294        push(@implContentDecls, <<END);
    1295     info.Holder()->DeleteHiddenValue(v8String("${attrName}", info.GetIsolate())); // Invalidate the cached value.
     1295    info.Holder()->DeleteHiddenValue(v8::String::NewSymbol("${attrName}")); // Invalidate the cached value.
    12961296END
    12971297    }
     
    20992099    v8::Local<v8::ObjectTemplate> instance = result->InstanceTemplate();
    21002100    instance->SetInternalFieldCount(V8${implClassName}::internalFieldCount);
    2101     result->SetClassName(v8String("${implClassName}"));
     2101    result->SetClassName(v8::String::NewSymbol("${implClassName}"));
    21022102    result->Inherit(V8${implClassName}::GetTemplate());
    21032103
     
    22992299
    23002300    // $commentInfo
    2301     ${conditional}$template->SetAccessor(v8String("$name"), ${interfaceName}V8Internal::${name}AttrGetter, ${interfaceName}V8Internal::${interfaceName}DomainSafeFunctionSetter, v8Undefined(), v8::ALL_CAN_READ, static_cast<v8::PropertyAttribute>($property_attributes));
     2301    ${conditional}$template->SetAccessor(v8::String::NewSymbol("$name"), ${interfaceName}V8Internal::${name}AttrGetter, ${interfaceName}V8Internal::${interfaceName}DomainSafeFunctionSetter, v8Undefined(), v8::ALL_CAN_READ, static_cast<v8::PropertyAttribute>($property_attributes));
    23022302END
    23032303        return;
     
    23302330    push(@implContent, "#if ${conditionalString}\n") if $conditionalString;
    23312331
    2332     push(@implContent, "    ${conditional}$template->Set(v8String(\"$name\"), v8::FunctionTemplate::New($callback, v8Undefined(), ${signature})$property_attributes);\n");
     2332    push(@implContent, "    ${conditional}$template->Set(v8::String::NewSymbol(\"$name\"), v8::FunctionTemplate::New($callback, v8Undefined(), ${signature})$property_attributes);\n");
    23332333
    23342334    push(@implContent, "#endif // ${conditionalString}\n") if $conditionalString;
     
    29522952    // For security reasons, these functions are on the instance instead
    29532953    // of on the prototype object to ensure that they cannot be overwritten.
    2954     instance->SetAccessor(v8String("reload"), V8Location::reloadAccessorGetter, 0, v8Undefined(), v8::ALL_CAN_READ, static_cast<v8::PropertyAttribute>(v8::DontDelete | v8::ReadOnly));
    2955     instance->SetAccessor(v8String("replace"), V8Location::replaceAccessorGetter, 0, v8Undefined(), v8::ALL_CAN_READ, static_cast<v8::PropertyAttribute>(v8::DontDelete | v8::ReadOnly));
    2956     instance->SetAccessor(v8String("assign"), V8Location::assignAccessorGetter, 0, v8Undefined(), v8::ALL_CAN_READ, static_cast<v8::PropertyAttribute>(v8::DontDelete | v8::ReadOnly));
     2954    instance->SetAccessor(v8::String::NewSymbol("reload"), V8Location::reloadAccessorGetter, 0, v8Undefined(), v8::ALL_CAN_READ, static_cast<v8::PropertyAttribute>(v8::DontDelete | v8::ReadOnly));
     2955    instance->SetAccessor(v8::String::NewSymbol("replace"), V8Location::replaceAccessorGetter, 0, v8Undefined(), v8::ALL_CAN_READ, static_cast<v8::PropertyAttribute>(v8::DontDelete | v8::ReadOnly));
     2956    instance->SetAccessor(v8::String::NewSymbol("assign"), V8Location::assignAccessorGetter, 0, v8Undefined(), v8::ALL_CAN_READ, static_cast<v8::PropertyAttribute>(v8::DontDelete | v8::ReadOnly));
    29572957END
    29582958    }
     
    30413041                my $callback = GetFunctionTemplateCallbackName($runtimeFunc, $interfaceName);
    30423042                push(@implContent, <<END);
    3043         proto->Set(v8String("${name}"), v8::FunctionTemplate::New(${callback}, v8Undefined(), defaultSignature)->GetFunction());
     3043        proto->Set(v8::String::NewSymbol("${name}"), v8::FunctionTemplate::New(${callback}, v8Undefined(), defaultSignature)->GetFunction());
    30443044END
    30453045                push(@implContent, "    }\n");
  • trunk/Source/WebCore/bindings/scripts/test/V8/V8Float64Array.cpp

    r126393 r126397  
    109109    v8::Handle<v8::FunctionTemplate> fooArgv[fooArgc] = { V8Float32Array::GetRawTemplate() };
    110110    v8::Handle<v8::Signature> fooSignature = v8::Signature::New(desc, fooArgc, fooArgv);
    111     proto->Set(v8String("foo"), v8::FunctionTemplate::New(Float64ArrayV8Internal::fooCallback, v8Undefined(), fooSignature));
     111    proto->Set(v8::String::NewSymbol("foo"), v8::FunctionTemplate::New(Float64ArrayV8Internal::fooCallback, v8Undefined(), fooSignature));
    112112
    113113    // Custom toString template
  • trunk/Source/WebCore/bindings/scripts/test/V8/V8TestActiveDOMObject.cpp

    r126393 r126397  
    135135    v8::Handle<v8::FunctionTemplate> excitingFunctionArgv[excitingFunctionArgc] = { V8Node::GetRawTemplate() };
    136136    v8::Handle<v8::Signature> excitingFunctionSignature = v8::Signature::New(desc, excitingFunctionArgc, excitingFunctionArgv);
    137     proto->Set(v8String("excitingFunction"), v8::FunctionTemplate::New(TestActiveDOMObjectV8Internal::excitingFunctionCallback, v8Undefined(), excitingFunctionSignature));
     137    proto->Set(v8::String::NewSymbol("excitingFunction"), v8::FunctionTemplate::New(TestActiveDOMObjectV8Internal::excitingFunctionCallback, v8Undefined(), excitingFunctionSignature));
    138138
    139139    // Function 'postMessage' (ExtAttr: 'DoNotCheckSecurity')
    140     proto->SetAccessor(v8String("postMessage"), TestActiveDOMObjectV8Internal::postMessageAttrGetter, TestActiveDOMObjectV8Internal::TestActiveDOMObjectDomainSafeFunctionSetter, v8Undefined(), v8::ALL_CAN_READ, static_cast<v8::PropertyAttribute>(v8::DontDelete));
     140    proto->SetAccessor(v8::String::NewSymbol("postMessage"), TestActiveDOMObjectV8Internal::postMessageAttrGetter, TestActiveDOMObjectV8Internal::TestActiveDOMObjectDomainSafeFunctionSetter, v8Undefined(), v8::ALL_CAN_READ, static_cast<v8::PropertyAttribute>(v8::DontDelete));
    141141
    142142    // Custom toString template
  • trunk/Source/WebCore/bindings/scripts/test/V8/V8TestEventTarget.cpp

    r126393 r126397  
    133133    v8::Handle<v8::FunctionTemplate> dispatchEventArgv[dispatchEventArgc] = { V8Event::GetRawTemplate() };
    134134    v8::Handle<v8::Signature> dispatchEventSignature = v8::Signature::New(desc, dispatchEventArgc, dispatchEventArgv);
    135     proto->Set(v8String("dispatchEvent"), v8::FunctionTemplate::New(TestEventTargetV8Internal::dispatchEventCallback, v8Undefined(), dispatchEventSignature));
     135    proto->Set(v8::String::NewSymbol("dispatchEvent"), v8::FunctionTemplate::New(TestEventTargetV8Internal::dispatchEventCallback, v8Undefined(), dispatchEventSignature));
    136136
    137137    // Custom toString template
  • trunk/Source/WebCore/bindings/scripts/test/V8/V8TestInterface.cpp

    r126393 r126397  
    297297    v8::Handle<v8::Signature> supplementalMethod2Signature = v8::Signature::New(desc, supplementalMethod2Argc, supplementalMethod2Argv);
    298298#if ENABLE(Condition11) || ENABLE(Condition12)
    299     proto->Set(v8String("supplementalMethod2"), v8::FunctionTemplate::New(TestInterfaceV8Internal::supplementalMethod2Callback, v8Undefined(), supplementalMethod2Signature));
    300 #endif // ENABLE(Condition11) || ENABLE(Condition12)
    301 #if ENABLE(Condition11) || ENABLE(Condition12)
    302     desc->Set(v8String("supplementalMethod4"), v8::FunctionTemplate::New(TestInterfaceV8Internal::supplementalMethod4Callback, v8Undefined(), v8::Local<v8::Signature>()));
     299    proto->Set(v8::String::NewSymbol("supplementalMethod2"), v8::FunctionTemplate::New(TestInterfaceV8Internal::supplementalMethod2Callback, v8Undefined(), supplementalMethod2Signature));
     300#endif // ENABLE(Condition11) || ENABLE(Condition12)
     301#if ENABLE(Condition11) || ENABLE(Condition12)
     302    desc->Set(v8::String::NewSymbol("supplementalMethod4"), v8::FunctionTemplate::New(TestInterfaceV8Internal::supplementalMethod4Callback, v8Undefined(), v8::Local<v8::Signature>()));
    303303#endif // ENABLE(Condition11) || ENABLE(Condition12)
    304304    V8DOMConfiguration::batchConfigureConstants(desc, proto, TestInterfaceConsts, WTF_ARRAY_LENGTH(TestInterfaceConsts));
  • trunk/Source/WebCore/bindings/scripts/test/V8/V8TestNamedConstructor.cpp

    r126393 r126397  
    9696    v8::Local<v8::ObjectTemplate> instance = result->InstanceTemplate();
    9797    instance->SetInternalFieldCount(V8TestNamedConstructor::internalFieldCount);
    98     result->SetClassName(v8String("TestNamedConstructor"));
     98    result->SetClassName(v8::String::NewSymbol("TestNamedConstructor"));
    9999    result->Inherit(V8TestNamedConstructor::GetTemplate());
    100100
  • trunk/Source/WebCore/bindings/scripts/test/V8/V8TestObj.cpp

    r126393 r126397  
    21942194    v8::Handle<v8::FunctionTemplate> voidMethodWithArgsArgv[voidMethodWithArgsArgc] = { v8::Handle<v8::FunctionTemplate>(), v8::Handle<v8::FunctionTemplate>(), V8TestObj::GetRawTemplate() };
    21952195    v8::Handle<v8::Signature> voidMethodWithArgsSignature = v8::Signature::New(desc, voidMethodWithArgsArgc, voidMethodWithArgsArgv);
    2196     proto->Set(v8String("voidMethodWithArgs"), v8::FunctionTemplate::New(TestObjV8Internal::voidMethodWithArgsCallback, v8Undefined(), voidMethodWithArgsSignature));
     2196    proto->Set(v8::String::NewSymbol("voidMethodWithArgs"), v8::FunctionTemplate::New(TestObjV8Internal::voidMethodWithArgsCallback, v8Undefined(), voidMethodWithArgsSignature));
    21972197
    21982198    // Custom Signature 'MethodWithArgs'
     
    22002200    v8::Handle<v8::FunctionTemplate> MethodWithArgsArgv[MethodWithArgsArgc] = { v8::Handle<v8::FunctionTemplate>(), v8::Handle<v8::FunctionTemplate>(), V8TestObj::GetRawTemplate() };
    22012201    v8::Handle<v8::Signature> MethodWithArgsSignature = v8::Signature::New(desc, MethodWithArgsArgc, MethodWithArgsArgv);
    2202     proto->Set(v8String("MethodWithArgs"), v8::FunctionTemplate::New(TestObjV8Internal::MethodWithArgsCallback, v8Undefined(), MethodWithArgsSignature));
     2202    proto->Set(v8::String::NewSymbol("MethodWithArgs"), v8::FunctionTemplate::New(TestObjV8Internal::MethodWithArgsCallback, v8Undefined(), MethodWithArgsSignature));
    22032203
    22042204    // Custom Signature 'objMethodWithArgs'
     
    22062206    v8::Handle<v8::FunctionTemplate> objMethodWithArgsArgv[objMethodWithArgsArgc] = { v8::Handle<v8::FunctionTemplate>(), v8::Handle<v8::FunctionTemplate>(), V8TestObj::GetRawTemplate() };
    22072207    v8::Handle<v8::Signature> objMethodWithArgsSignature = v8::Signature::New(desc, objMethodWithArgsArgc, objMethodWithArgsArgv);
    2208     proto->Set(v8String("objMethodWithArgs"), v8::FunctionTemplate::New(TestObjV8Internal::objMethodWithArgsCallback, v8Undefined(), objMethodWithArgsSignature));
     2208    proto->Set(v8::String::NewSymbol("objMethodWithArgs"), v8::FunctionTemplate::New(TestObjV8Internal::objMethodWithArgsCallback, v8Undefined(), objMethodWithArgsSignature));
    22092209
    22102210    // Custom Signature 'methodWithSequenceArg'
     
    22122212    v8::Handle<v8::FunctionTemplate> methodWithSequenceArgArgv[methodWithSequenceArgArgc] = { V8sequence<ScriptProfile>::GetRawTemplate() };
    22132213    v8::Handle<v8::Signature> methodWithSequenceArgSignature = v8::Signature::New(desc, methodWithSequenceArgArgc, methodWithSequenceArgArgv);
    2214     proto->Set(v8String("methodWithSequenceArg"), v8::FunctionTemplate::New(TestObjV8Internal::methodWithSequenceArgCallback, v8Undefined(), methodWithSequenceArgSignature));
     2214    proto->Set(v8::String::NewSymbol("methodWithSequenceArg"), v8::FunctionTemplate::New(TestObjV8Internal::methodWithSequenceArgCallback, v8Undefined(), methodWithSequenceArgSignature));
    22152215
    22162216    // Custom Signature 'methodThatRequiresAllArgsAndThrows'
     
    22182218    v8::Handle<v8::FunctionTemplate> methodThatRequiresAllArgsAndThrowsArgv[methodThatRequiresAllArgsAndThrowsArgc] = { v8::Handle<v8::FunctionTemplate>(), V8TestObj::GetRawTemplate() };
    22192219    v8::Handle<v8::Signature> methodThatRequiresAllArgsAndThrowsSignature = v8::Signature::New(desc, methodThatRequiresAllArgsAndThrowsArgc, methodThatRequiresAllArgsAndThrowsArgv);
    2220     proto->Set(v8String("methodThatRequiresAllArgsAndThrows"), v8::FunctionTemplate::New(TestObjV8Internal::methodThatRequiresAllArgsAndThrowsCallback, v8Undefined(), methodThatRequiresAllArgsAndThrowsSignature));
    2221     desc->Set(v8String("classMethod"), v8::FunctionTemplate::New(TestObjV8Internal::classMethodCallback, v8Undefined(), v8::Local<v8::Signature>()));
    2222     desc->Set(v8String("classMethodWithOptional"), v8::FunctionTemplate::New(TestObjV8Internal::classMethodWithOptionalCallback, v8Undefined(), v8::Local<v8::Signature>()));
    2223     desc->Set(v8String("classMethod2"), v8::FunctionTemplate::New(V8TestObj::classMethod2Callback, v8Undefined(), v8::Local<v8::Signature>()));
     2220    proto->Set(v8::String::NewSymbol("methodThatRequiresAllArgsAndThrows"), v8::FunctionTemplate::New(TestObjV8Internal::methodThatRequiresAllArgsAndThrowsCallback, v8Undefined(), methodThatRequiresAllArgsAndThrowsSignature));
     2221    desc->Set(v8::String::NewSymbol("classMethod"), v8::FunctionTemplate::New(TestObjV8Internal::classMethodCallback, v8Undefined(), v8::Local<v8::Signature>()));
     2222    desc->Set(v8::String::NewSymbol("classMethodWithOptional"), v8::FunctionTemplate::New(TestObjV8Internal::classMethodWithOptionalCallback, v8Undefined(), v8::Local<v8::Signature>()));
     2223    desc->Set(v8::String::NewSymbol("classMethod2"), v8::FunctionTemplate::New(V8TestObj::classMethod2Callback, v8Undefined(), v8::Local<v8::Signature>()));
    22242224#if ENABLE(Condition1)
    2225     desc->Set(v8String("overloadedMethod1"), v8::FunctionTemplate::New(TestObjV8Internal::overloadedMethod1Callback, v8Undefined(), v8::Local<v8::Signature>()));
     2225    desc->Set(v8::String::NewSymbol("overloadedMethod1"), v8::FunctionTemplate::New(TestObjV8Internal::overloadedMethod1Callback, v8Undefined(), v8::Local<v8::Signature>()));
    22262226#endif // ENABLE(Condition1)
    22272227    if (RuntimeEnabledFeatures::enabledAtRuntimeMethod1Enabled())
    2228         proto->Set(v8String("enabledAtRuntimeMethod1"), v8::FunctionTemplate::New(TestObjV8Internal::enabledAtRuntimeMethod1Callback, v8Undefined(), defaultSignature));
     2228        proto->Set(v8::String::NewSymbol("enabledAtRuntimeMethod1"), v8::FunctionTemplate::New(TestObjV8Internal::enabledAtRuntimeMethod1Callback, v8Undefined(), defaultSignature));
    22292229    if (RuntimeEnabledFeatures::featureNameEnabled())
    2230         proto->Set(v8String("enabledAtRuntimeMethod2"), v8::FunctionTemplate::New(TestObjV8Internal::enabledAtRuntimeMethod2Callback, v8Undefined(), defaultSignature));
     2230        proto->Set(v8::String::NewSymbol("enabledAtRuntimeMethod2"), v8::FunctionTemplate::New(TestObjV8Internal::enabledAtRuntimeMethod2Callback, v8Undefined(), defaultSignature));
    22312231
    22322232    // Custom Signature 'convert1'
     
    22342234    v8::Handle<v8::FunctionTemplate> convert1Argv[convert1Argc] = { V8a::GetRawTemplate() };
    22352235    v8::Handle<v8::Signature> convert1Signature = v8::Signature::New(desc, convert1Argc, convert1Argv);
    2236     proto->Set(v8String("convert1"), v8::FunctionTemplate::New(TestObjV8Internal::convert1Callback, v8Undefined(), convert1Signature));
     2236    proto->Set(v8::String::NewSymbol("convert1"), v8::FunctionTemplate::New(TestObjV8Internal::convert1Callback, v8Undefined(), convert1Signature));
    22372237
    22382238    // Custom Signature 'convert2'
     
    22402240    v8::Handle<v8::FunctionTemplate> convert2Argv[convert2Argc] = { V8b::GetRawTemplate() };
    22412241    v8::Handle<v8::Signature> convert2Signature = v8::Signature::New(desc, convert2Argc, convert2Argv);
    2242     proto->Set(v8String("convert2"), v8::FunctionTemplate::New(TestObjV8Internal::convert2Callback, v8Undefined(), convert2Signature));
     2242    proto->Set(v8::String::NewSymbol("convert2"), v8::FunctionTemplate::New(TestObjV8Internal::convert2Callback, v8Undefined(), convert2Signature));
    22432243
    22442244    // Custom Signature 'convert4'
     
    22462246    v8::Handle<v8::FunctionTemplate> convert4Argv[convert4Argc] = { V8d::GetRawTemplate() };
    22472247    v8::Handle<v8::Signature> convert4Signature = v8::Signature::New(desc, convert4Argc, convert4Argv);
    2248     proto->Set(v8String("convert4"), v8::FunctionTemplate::New(TestObjV8Internal::convert4Callback, v8Undefined(), convert4Signature));
     2248    proto->Set(v8::String::NewSymbol("convert4"), v8::FunctionTemplate::New(TestObjV8Internal::convert4Callback, v8Undefined(), convert4Signature));
    22492249
    22502250    // Custom Signature 'convert5'
     
    22522252    v8::Handle<v8::FunctionTemplate> convert5Argv[convert5Argc] = { V8e::GetRawTemplate() };
    22532253    v8::Handle<v8::Signature> convert5Signature = v8::Signature::New(desc, convert5Argc, convert5Argv);
    2254     proto->Set(v8String("convert5"), v8::FunctionTemplate::New(TestObjV8Internal::convert5Callback, v8Undefined(), convert5Signature));
     2254    proto->Set(v8::String::NewSymbol("convert5"), v8::FunctionTemplate::New(TestObjV8Internal::convert5Callback, v8Undefined(), convert5Signature));
    22552255    V8DOMConfiguration::batchConfigureConstants(desc, proto, TestObjConsts, WTF_ARRAY_LENGTH(TestObjConsts));
    22562256
     
    23122312    UNUSED_PARAM(defaultSignature); // In some cases, it will not be used.
    23132313    if (ContextFeatures::enabledPerContextMethod1Enabled(impl->document())) {
    2314         proto->Set(v8String("enabledPerContextMethod1"), v8::FunctionTemplate::New(TestObjV8Internal::enabledPerContextMethod1Callback, v8Undefined(), defaultSignature)->GetFunction());
     2314        proto->Set(v8::String::NewSymbol("enabledPerContextMethod1"), v8::FunctionTemplate::New(TestObjV8Internal::enabledPerContextMethod1Callback, v8Undefined(), defaultSignature)->GetFunction());
    23152315    }
    23162316    if (ContextFeatures::featureNameEnabled(impl->document())) {
    2317         proto->Set(v8String("enabledPerContextMethod2"), v8::FunctionTemplate::New(TestObjV8Internal::enabledPerContextMethod2Callback, v8Undefined(), defaultSignature)->GetFunction());
     2317        proto->Set(v8::String::NewSymbol("enabledPerContextMethod2"), v8::FunctionTemplate::New(TestObjV8Internal::enabledPerContextMethod2Callback, v8Undefined(), defaultSignature)->GetFunction());
    23182318    }
    23192319}
  • trunk/Source/WebCore/bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp

    r126393 r126397  
    7373{
    7474    INC_STATS("DOM.TestSerializedScriptValueInterface.cachedValue._get");
    75     v8::Handle<v8::String> propertyName = v8String("cachedValue", info.GetIsolate());
     75    v8::Handle<v8::String> propertyName = v8::String::NewSymbol("cachedValue");
    7676    v8::Handle<v8::Value> value = info.Holder()->GetHiddenValue(propertyName);
    7777    if (!value.IsEmpty())
     
    9090    RefPtr<SerializedScriptValue> v = SerializedScriptValue::create(value, info.GetIsolate());
    9191    imp->setCachedValue(WTF::getPtr(v));
    92     info.Holder()->DeleteHiddenValue(v8String("cachedValue", info.GetIsolate())); // Invalidate the cached value.
     92    info.Holder()->DeleteHiddenValue(v8::String::NewSymbol("cachedValue")); // Invalidate the cached value.
    9393    return;
    9494}
     
    111111{
    112112    INC_STATS("DOM.TestSerializedScriptValueInterface.cachedReadonlyValue._get");
    113     v8::Handle<v8::String> propertyName = v8String("cachedReadonlyValue", info.GetIsolate());
     113    v8::Handle<v8::String> propertyName = v8::String::NewSymbol("cachedReadonlyValue");
    114114    v8::Handle<v8::Value> value = info.Holder()->GetHiddenValue(propertyName);
    115115    if (!value.IsEmpty())
  • trunk/Source/WebCore/bindings/v8/V8Binding.h

    r126377 r126397  
    9999    }
    100100
    101     // Convert a WebCore String to a V8 string.
     101    // Convert a string to a V8 string.
    102102    inline v8::Handle<v8::String> v8String(const String& string, v8::Isolate* isolate = 0)
    103103    {
    104104        return v8ExternalString(string, isolate);
    105     }
    106 
    107     // Convert a char* string to a V8 string.
    108     inline v8::Handle<v8::String> v8String(const char* string, v8::Isolate* isolate = 0)
    109     {
    110         return v8ExternalString(String(string), isolate);
    111105    }
    112106
Note: See TracChangeset for help on using the changeset viewer.