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

Side by Side Diff: Source/bindings/tests/results/core/V8TestInterfaceNotScriptWrappable.cpp

Issue 611953003: Canvas2D Performance: fix the bottleneck of hasInstance during JS binding -- overloading (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: add code change in Source/bindings/tests/results/ Created 6 years, 2 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 "config.h" 7 #include "config.h"
8 #include "V8TestInterfaceNotScriptWrappable.h" 8 #include "V8TestInterfaceNotScriptWrappable.h"
9 9
10 #include "bindings/core/v8/ExceptionState.h" 10 #include "bindings/core/v8/ExceptionState.h"
(...skipping 27 matching lines...) Expand all
38 { 38 {
39 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter"); 39 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter");
40 TestInterfaceNotScriptWrappableV8Internal::attr1AttributeGetter(info); 40 TestInterfaceNotScriptWrappableV8Internal::attr1AttributeGetter(info);
41 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 41 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
42 } 42 }
43 43
44 static void attr1AttributeSetter(v8::Local<v8::Value> v8Value, const v8::Propert yCallbackInfo<void>& info) 44 static void attr1AttributeSetter(v8::Local<v8::Value> v8Value, const v8::Propert yCallbackInfo<void>& info)
45 { 45 {
46 v8::Handle<v8::Object> holder = info.Holder(); 46 v8::Handle<v8::Object> holder = info.Holder();
47 TestInterfaceNotScriptWrappable* impl = V8TestInterfaceNotScriptWrappable::t oImpl(holder); 47 TestInterfaceNotScriptWrappable* impl = V8TestInterfaceNotScriptWrappable::t oImpl(holder);
48 TestInterfaceNotScriptWrappable* cppValue = V8TestInterfaceNotScriptWrappabl e::toImplWithTypeCheck(info.GetIsolate(), v8Value); 48 TestInterfaceNotScriptWrappable* cppValue = V8TestInterfaceNotScriptWrappabl e::toImpl(v8::Handle<v8::Object>::Cast(v8Value));
49 impl->setAttr1(WTF::getPtr(cppValue)); 49 impl->setAttr1(WTF::getPtr(cppValue));
50 } 50 }
51 51
52 static void attr1AttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::Va lue> v8Value, const v8::PropertyCallbackInfo<void>& info) 52 static void attr1AttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::Va lue> v8Value, const v8::PropertyCallbackInfo<void>& info)
53 { 53 {
54 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter"); 54 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter");
55 TestInterfaceNotScriptWrappableV8Internal::attr1AttributeSetter(v8Value, inf o); 55 TestInterfaceNotScriptWrappableV8Internal::attr1AttributeSetter(v8Value, inf o);
56 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 56 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
57 } 57 }
58 58
59 static void funcMethod(const v8::FunctionCallbackInfo<v8::Value>& info) 59 static void funcMethod(const v8::FunctionCallbackInfo<v8::Value>& info)
60 { 60 {
61 if (UNLIKELY(info.Length() < 1)) { 61 if (UNLIKELY(info.Length() < 1)) {
62 V8ThrowException::throwException(createMinimumArityTypeErrorForMethod("f unc", "TestInterfaceNotScriptWrappable", 1, info.Length(), info.GetIsolate()), i nfo.GetIsolate()); 62 V8ThrowException::throwException(createMinimumArityTypeErrorForMethod("f unc", "TestInterfaceNotScriptWrappable", 1, info.Length(), info.GetIsolate()), i nfo.GetIsolate());
63 return; 63 return;
64 } 64 }
65 TestInterfaceNotScriptWrappable* impl = V8TestInterfaceNotScriptWrappable::t oImpl(info.Holder()); 65 TestInterfaceNotScriptWrappable* impl = V8TestInterfaceNotScriptWrappable::t oImpl(info.Holder());
66 TestInterfaceNotScriptWrappable* arg; 66 TestInterfaceNotScriptWrappable* arg;
67 { 67 {
68 arg = V8TestInterfaceNotScriptWrappable::toImplWithTypeCheck(info.GetIso late(), info[0]); 68 arg = V8TestInterfaceNotScriptWrappable::toImpl(v8::Handle<v8::Object>:: Cast(info[0]));
69 } 69 }
70 impl->func(arg); 70 impl->func(arg);
71 } 71 }
72 72
73 static void funcMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) 73 static void funcMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info)
74 { 74 {
75 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod"); 75 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod");
76 TestInterfaceNotScriptWrappableV8Internal::funcMethod(info); 76 TestInterfaceNotScriptWrappableV8Internal::funcMethod(info);
77 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 77 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
78 } 78 }
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
162 return 0; 162 return 0;
163 } 163 }
164 164
165 template<> 165 template<>
166 v8::Handle<v8::Value> toV8NoInline(TestInterfaceNotScriptWrappable* impl, v8::Ha ndle<v8::Object> creationContext, v8::Isolate* isolate) 166 v8::Handle<v8::Value> toV8NoInline(TestInterfaceNotScriptWrappable* impl, v8::Ha ndle<v8::Object> creationContext, v8::Isolate* isolate)
167 { 167 {
168 return toV8(impl, creationContext, isolate); 168 return toV8(impl, creationContext, isolate);
169 } 169 }
170 170
171 } // namespace blink 171 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698