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

Unified Diff: Source/bindings/scripts/v8_types.py

Issue 1051753003: bindings: Add toBoolean() to V8Binding.h (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 8 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/core/v8/V8Binding.cpp ('k') | Source/bindings/tests/results/core/V8TestDictionary.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/scripts/v8_types.py
diff --git a/Source/bindings/scripts/v8_types.py b/Source/bindings/scripts/v8_types.py
index dcce52845ade81fd27a782f71c4a7199b08ca247..2a3e5bc8b2612d2a9adf7b748d38aa2d80051945 100644
--- a/Source/bindings/scripts/v8_types.py
+++ b/Source/bindings/scripts/v8_types.py
@@ -472,7 +472,7 @@ V8_VALUE_TO_CPP_VALUE = {
'DOMString': '{v8_value}',
'ByteString': 'toByteString({isolate}, {arguments})',
'USVString': 'toUSVString({isolate}, {arguments})',
- 'boolean': '{v8_value}->BooleanValue()',
+ 'boolean': 'toBoolean({isolate}, {arguments})',
'float': 'toRestrictedFloat({isolate}, {arguments})',
'unrestricted float': 'toFloat({isolate}, {arguments})',
'double': 'toRestrictedDouble({isolate}, {arguments})',
@@ -501,7 +501,7 @@ def v8_conversion_needs_exception_state(idl_type):
return (idl_type.is_numeric_type or
idl_type.is_enum or
idl_type.is_dictionary or
- idl_type.name in ('ByteString', 'Dictionary', 'USVString', 'SerializedScriptValue'))
+ idl_type.name in ('Boolean', 'ByteString', 'Dictionary', 'USVString', 'SerializedScriptValue'))
IdlType.v8_conversion_needs_exception_state = property(v8_conversion_needs_exception_state)
IdlArrayOrSequenceType.v8_conversion_needs_exception_state = True
« no previous file with comments | « Source/bindings/core/v8/V8Binding.cpp ('k') | Source/bindings/tests/results/core/V8TestDictionary.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698