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

Unified Diff: Source/bindings/tests/results/V8TestTypedefs.cpp

Issue 121113004: Improve handling of failed integer type conversions. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase Created 6 years, 11 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 | « Source/bindings/tests/results/V8TestObjectPython.cpp ('k') | Source/bindings/v8/Dictionary.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/tests/results/V8TestTypedefs.cpp
diff --git a/Source/bindings/tests/results/V8TestTypedefs.cpp b/Source/bindings/tests/results/V8TestTypedefs.cpp
index 72cc4f94adc28efce95ed4be0837f552811e5541..399fd1d7d37b20f88c6525241b8f036975381c09 100644
--- a/Source/bindings/tests/results/V8TestTypedefs.cpp
+++ b/Source/bindings/tests/results/V8TestTypedefs.cpp
@@ -90,8 +90,9 @@ static void unsignedLongLongAttrAttributeGetterCallback(v8::Local<v8::String>, c
static void unsignedLongLongAttrAttributeSetter(v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info)
{
+ ExceptionState exceptionState(ExceptionState::SetterContext, "unsignedLongLongAttr", "TestTypedefs", info.Holder(), info.GetIsolate());
TestTypedefs* imp = V8TestTypedefs::toNative(info.Holder());
- V8TRYCATCH_VOID(unsigned long long, cppValue, toUInt64(jsValue));
+ V8TRYCATCH_EXCEPTION_VOID(unsigned long long, cppValue, toUInt64(jsValue, exceptionState), exceptionState);
imp->setUnsignedLongLongAttr(cppValue);
}
@@ -148,8 +149,9 @@ static void attrWithGetterExceptionAttributeGetterCallback(v8::Local<v8::String>
static void attrWithGetterExceptionAttributeSetter(v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info)
{
+ ExceptionState exceptionState(ExceptionState::SetterContext, "attrWithGetterException", "TestTypedefs", info.Holder(), info.GetIsolate());
TestTypedefs* imp = V8TestTypedefs::toNative(info.Holder());
- V8TRYCATCH_VOID(int, cppValue, toInt32(jsValue));
+ V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), exceptionState);
imp->setAttrWithGetterException(cppValue);
}
@@ -177,7 +179,7 @@ static void attrWithSetterExceptionAttributeSetter(v8::Local<v8::Value> jsValue,
{
ExceptionState exceptionState(ExceptionState::SetterContext, "attrWithSetterException", "TestTypedefs", info.Holder(), info.GetIsolate());
TestTypedefs* imp = V8TestTypedefs::toNative(info.Holder());
- V8TRYCATCH_VOID(int, cppValue, toInt32(jsValue));
+ V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), exceptionState);
imp->setAttrWithSetterException(cppValue, exceptionState);
exceptionState.throwIfNeeded();
}
« no previous file with comments | « Source/bindings/tests/results/V8TestObjectPython.cpp ('k') | Source/bindings/v8/Dictionary.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698