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

Side by Side Diff: third_party/WebKit/Source/bindings/tests/results/core/V8TestSpecialOperations.cpp

Issue 2301993002: binding: Introduces ExceptionToPromiseScope. (Closed)
Patch Set: Addressed review comments (rename, empty line). Created 4 years, 3 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // This file has been auto-generated by code_generator_v8.py. DO NOT MODIFY! 5 // This file has been auto-generated by code_generator_v8.py. DO NOT MODIFY!
6 6
7 #include "V8TestSpecialOperations.h" 7 #include "V8TestSpecialOperations.h"
8 8
9 #include "bindings/core/v8/ExceptionState.h" 9 #include "bindings/core/v8/ExceptionState.h"
10 #include "bindings/core/v8/GeneratedCodeHelper.h" 10 #include "bindings/core/v8/GeneratedCodeHelper.h"
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 std::is_same<decltype(&TestSpecialOperations::hasPendingActivity), 49 std::is_same<decltype(&TestSpecialOperations::hasPendingActivity),
50 decltype(&ScriptWrappable::hasPendingActivity)>::value, 50 decltype(&ScriptWrappable::hasPendingActivity)>::value,
51 "TestSpecialOperations is overriding hasPendingActivity(), but is not specif ying " 51 "TestSpecialOperations is overriding hasPendingActivity(), but is not specif ying "
52 "[ActiveScriptWrappable] extended attribute in the IDL file. " 52 "[ActiveScriptWrappable] extended attribute in the IDL file. "
53 "Be consistent."); 53 "Be consistent.");
54 54
55 namespace TestSpecialOperationsV8Internal { 55 namespace TestSpecialOperationsV8Internal {
56 56
57 static void namedItemMethod(const v8::FunctionCallbackInfo<v8::Value>& info) 57 static void namedItemMethod(const v8::FunctionCallbackInfo<v8::Value>& info)
58 { 58 {
59 TestSpecialOperations* impl = V8TestSpecialOperations::toImpl(info.Holder()) ;
60
59 if (UNLIKELY(info.Length() < 1)) { 61 if (UNLIKELY(info.Length() < 1)) {
60 V8ThrowException::throwException(info.GetIsolate(), V8ThrowException::cr eateTypeError(info.GetIsolate(), ExceptionMessages::failedToExecute("namedItem", "TestSpecialOperations", ExceptionMessages::notEnoughArguments(1, info.Length() )))); 62 V8ThrowException::throwTypeError(info.GetIsolate(), ExceptionMessages::f ailedToExecute("namedItem", "TestSpecialOperations", ExceptionMessages::notEnoug hArguments(1, info.Length())));
61 return; 63 return;
62 } 64 }
63 TestSpecialOperations* impl = V8TestSpecialOperations::toImpl(info.Holder()) ; 65
64 V8StringResource<> name; 66 V8StringResource<> name;
65 { 67 name = info[0];
66 name = info[0]; 68 if (!name.prepare())
67 if (!name.prepare()) 69 return;
68 return; 70
69 }
70 NodeOrNodeList result; 71 NodeOrNodeList result;
71 impl->getItem(name, result); 72 impl->getItem(name, result);
72 v8SetReturnValue(info, result); 73 v8SetReturnValue(info, result);
73 } 74 }
74 75
75 static void namedItemMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& i nfo) 76 static void namedItemMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& i nfo)
76 { 77 {
77 TestSpecialOperationsV8Internal::namedItemMethod(info); 78 TestSpecialOperationsV8Internal::namedItemMethod(info);
78 } 79 }
79 80
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after
215 { 216 {
216 return V8PerIsolateData::from(isolate)->findInstanceInPrototypeChain(&wrappe rTypeInfo, v8Value); 217 return V8PerIsolateData::from(isolate)->findInstanceInPrototypeChain(&wrappe rTypeInfo, v8Value);
217 } 218 }
218 219
219 TestSpecialOperations* V8TestSpecialOperations::toImplWithTypeCheck(v8::Isolate* isolate, v8::Local<v8::Value> value) 220 TestSpecialOperations* V8TestSpecialOperations::toImplWithTypeCheck(v8::Isolate* isolate, v8::Local<v8::Value> value)
220 { 221 {
221 return hasInstance(value, isolate) ? toImpl(v8::Local<v8::Object>::Cast(valu e)) : nullptr; 222 return hasInstance(value, isolate) ? toImpl(v8::Local<v8::Object>::Cast(valu e)) : nullptr;
222 } 223 }
223 224
224 } // namespace blink 225 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698