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

Unified Diff: third_party/WebKit/Source/bindings/scripts/v8_methods.py

Issue 2061113002: Remove ExceptionState::throwIfNeeded Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: temp Created 4 years, 5 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
Index: third_party/WebKit/Source/bindings/scripts/v8_methods.py
diff --git a/third_party/WebKit/Source/bindings/scripts/v8_methods.py b/third_party/WebKit/Source/bindings/scripts/v8_methods.py
index 002860c69c2312cb08ba7138c508e950bf03cfa9..9d5275f882aaad1af7615c728b79eb1659138d7e 100644
--- a/third_party/WebKit/Source/bindings/scripts/v8_methods.py
+++ b/third_party/WebKit/Source/bindings/scripts/v8_methods.py
@@ -424,11 +424,6 @@ def v8_value_to_local_cpp_variadic_value(method, argument, index, return_promise
idl_type = argument.idl_type
this_cpp_type = idl_type.cpp_type
- if method.returns_promise:
- check_expression = 'exceptionState.hadException()'
- else:
- check_expression = 'exceptionState.throwIfNeeded()'
-
if idl_type.is_dictionary or idl_type.is_union_type:
vector_type = 'HeapVector'
else:
@@ -436,7 +431,8 @@ def v8_value_to_local_cpp_variadic_value(method, argument, index, return_promise
return {
'assign_expression': 'toImplArguments<%s<%s>>(info, %s, exceptionState)' % (vector_type, this_cpp_type, index),
- 'check_expression': check_expression,
+ 'check_expression': 'exceptionState.hadException()',
+ 'clear_exception': 'exceptionState.clearException()' if method.returns_promise else '',
'cpp_type': this_cpp_type,
'cpp_name': argument.name,
'declare_variable': False,

Powered by Google App Engine
This is Rietveld 408576698