Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(98)

Unified Diff: third_party/WebKit/Source/bindings/tests/results/modules/V8TestInterface5.cpp

Issue 1993593003: binding: Check the type of property names in FooCallback instead of Foo. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/Source/bindings/tests/results/core/V8TestSpecialOperationsNotEnumerable.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/bindings/tests/results/modules/V8TestInterface5.cpp
diff --git a/third_party/WebKit/Source/bindings/tests/results/modules/V8TestInterface5.cpp b/third_party/WebKit/Source/bindings/tests/results/modules/V8TestInterface5.cpp
index ccd4da38983cee1dbc41674c518ef4a18672daf9..7b6d1761440cb8fd5fa3dd8327f02f330ec9c054 100644
--- a/third_party/WebKit/Source/bindings/tests/results/modules/V8TestInterface5.cpp
+++ b/third_party/WebKit/Source/bindings/tests/results/modules/V8TestInterface5.cpp
@@ -681,8 +681,6 @@ static void indexedPropertyDeleterCallback(uint32_t index, const v8::PropertyCal
static void namedPropertyGetter(v8::Local<v8::Name> name, const v8::PropertyCallbackInfo<v8::Value>& info)
{
- if (!name->IsString())
- return;
auto nameString = name.As<v8::String>();
TestInterface5Implementation* impl = V8TestInterface5::toImpl(info.Holder());
AtomicString propertyName = toCoreAtomicString(nameString);
@@ -694,13 +692,13 @@ static void namedPropertyGetter(v8::Local<v8::Name> name, const v8::PropertyCall
static void namedPropertyGetterCallback(v8::Local<v8::Name> name, const v8::PropertyCallbackInfo<v8::Value>& info)
{
+ if (!name->IsString())
+ return;
TestInterface5ImplementationV8Internal::namedPropertyGetter(name, info);
}
static void namedPropertySetter(v8::Local<v8::Name> name, v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<v8::Value>& info)
{
- if (!name->IsString())
- return;
auto nameString = name.As<v8::String>();
TestInterface5Implementation* impl = V8TestInterface5::toImpl(info.Holder());
V8StringResource<> propertyName(nameString);
@@ -717,13 +715,13 @@ static void namedPropertySetter(v8::Local<v8::Name> name, v8::Local<v8::Value> v
static void namedPropertySetterCallback(v8::Local<v8::Name> name, v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<v8::Value>& info)
{
+ if (!name->IsString())
+ return;
TestInterface5ImplementationV8Internal::namedPropertySetter(name, v8Value, info);
}
static void namedPropertyQuery(v8::Local<v8::Name> name, const v8::PropertyCallbackInfo<v8::Integer>& info)
{
- if (!name->IsString())
- return;
TestInterface5Implementation* impl = V8TestInterface5::toImpl(info.Holder());
AtomicString propertyName = toCoreAtomicString(name.As<v8::String>());
v8::String::Utf8Value namedProperty(name);
@@ -738,13 +736,13 @@ static void namedPropertyQuery(v8::Local<v8::Name> name, const v8::PropertyCallb
static void namedPropertyQueryCallback(v8::Local<v8::Name> name, const v8::PropertyCallbackInfo<v8::Integer>& info)
{
+ if (!name->IsString())
+ return;
TestInterface5ImplementationV8Internal::namedPropertyQuery(name, info);
}
static void namedPropertyDeleter(v8::Local<v8::Name> name, const v8::PropertyCallbackInfo<v8::Boolean>& info)
{
- if (!name->IsString())
- return;
TestInterface5Implementation* impl = V8TestInterface5::toImpl(info.Holder());
AtomicString propertyName = toCoreAtomicString(name.As<v8::String>());
DeleteResult result = impl->anonymousNamedDeleter(propertyName);
@@ -754,6 +752,8 @@ static void namedPropertyDeleter(v8::Local<v8::Name> name, const v8::PropertyCal
static void namedPropertyDeleterCallback(v8::Local<v8::Name> name, const v8::PropertyCallbackInfo<v8::Boolean>& info)
{
+ if (!name->IsString())
+ return;
TestInterface5ImplementationV8Internal::namedPropertyDeleter(name, info);
}
« no previous file with comments | « third_party/WebKit/Source/bindings/tests/results/core/V8TestSpecialOperationsNotEnumerable.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698