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

Side by Side Diff: Source/bindings/tests/results/core/V8TestObject.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: update code accordingly (w/o redundant type check for overload resolution) 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
« no previous file with comments | « Source/bindings/tests/idls/core/TestObject.idl ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "V8TestObject.h" 8 #include "V8TestObject.h"
9 9
10 #include "bindings/core/v8/BindingSecurity.h" 10 #include "bindings/core/v8/BindingSecurity.h"
(...skipping 9776 matching lines...) Expand 10 before | Expand all | Expand 10 after
9787 impl->useToImpl4ArgumentsCheckingIfPossibleWithUndefinedArg(node1, node2); 9787 impl->useToImpl4ArgumentsCheckingIfPossibleWithUndefinedArg(node1, node2);
9788 } 9788 }
9789 9789
9790 static void useToImpl4ArgumentsCheckingIfPossibleWithUndefinedArgMethodCallback( const v8::FunctionCallbackInfo<v8::Value>& info) 9790 static void useToImpl4ArgumentsCheckingIfPossibleWithUndefinedArgMethodCallback( const v8::FunctionCallbackInfo<v8::Value>& info)
9791 { 9791 {
9792 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod"); 9792 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod");
9793 TestObjectV8Internal::useToImpl4ArgumentsCheckingIfPossibleWithUndefinedArgM ethod(info); 9793 TestObjectV8Internal::useToImpl4ArgumentsCheckingIfPossibleWithUndefinedArgM ethod(info);
9794 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 9794 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
9795 } 9795 }
9796 9796
9797 static void typeCheckingMaybeRedundantForOverloadingMethodsA1Method(const v8::Fu nctionCallbackInfo<v8::Value>& info)
9798 {
9799 ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckin gMaybeRedundantForOverloadingMethodsA", "TestObject", info.Holder(), info.GetIso late());
9800 TestObject* impl = V8TestObject::toImpl(info.Holder());
9801 Node* a;
9802 int b;
9803 {
9804 a = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
9805 TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(b, toInt32(info[1], exceptionState ), exceptionState);
9806 }
9807 impl->typeCheckingMaybeRedundantForOverloadingMethodsA(a, b);
9808 }
9809
9810 static void typeCheckingMaybeRedundantForOverloadingMethodsA2Method(const v8::Fu nctionCallbackInfo<v8::Value>& info)
9811 {
9812 ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckin gMaybeRedundantForOverloadingMethodsA", "TestObject", info.Holder(), info.GetIso late());
9813 TestObject* impl = V8TestObject::toImpl(info.Holder());
9814 int a;
9815 int b;
9816 {
9817 TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(a, toInt32(info[0], exceptionState ), exceptionState);
9818 TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(b, toInt32(info[1], exceptionState ), exceptionState);
9819 }
9820 impl->typeCheckingMaybeRedundantForOverloadingMethodsA(a, b);
9821 }
9822
9823 static void typeCheckingMaybeRedundantForOverloadingMethodsAMethod(const v8::Fun ctionCallbackInfo<v8::Value>& info)
9824 {
9825 ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckin gMaybeRedundantForOverloadingMethodsA", "TestObject", info.Holder(), info.GetIso late());
9826 switch (std::min(2, info.Length())) {
9827 case 2:
9828 if (V8Node::hasInstance(info[0], info.GetIsolate())) {
9829 typeCheckingMaybeRedundantForOverloadingMethodsA1Method(info);
9830 return;
9831 }
9832 if (true) {
9833 typeCheckingMaybeRedundantForOverloadingMethodsA2Method(info);
9834 return;
9835 }
9836 break;
9837 default:
9838 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(2, i nfo.Length()));
9839 exceptionState.throwIfNeeded();
9840 return;
9841 }
9842 exceptionState.throwTypeError("No function was found that matched the signat ure provided.");
9843 exceptionState.throwIfNeeded();
9844 }
9845
9846 static void typeCheckingMaybeRedundantForOverloadingMethodsAMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info)
9847 {
9848 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod");
9849 TestObjectV8Internal::typeCheckingMaybeRedundantForOverloadingMethodsAMethod (info);
9850 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
9851 }
9852
9853 static void typeCheckingMaybeRedundantForOverloadingMethodsB1Method(const v8::Fu nctionCallbackInfo<v8::Value>& info)
9854 {
9855 TestObject* impl = V8TestObject::toImpl(info.Holder());
9856 Node* a;
9857 {
9858 if (info.Length() > 0 && !V8Node::hasInstance(info[0], info.GetIsolate() )) {
9859 V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute( "typeCheckingMaybeRedundantForOverloadingMethodsB", "TestObject", "parameter 1 i s not of type 'Node'."), info.GetIsolate());
9860 return;
9861 }
9862 a = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
9863 }
9864 impl->typeCheckingMaybeRedundantForOverloadingMethodsB(a);
9865 }
9866
9867 static void typeCheckingMaybeRedundantForOverloadingMethodsB2Method(const v8::Fu nctionCallbackInfo<v8::Value>& info)
9868 {
9869 ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckin gMaybeRedundantForOverloadingMethodsB", "TestObject", info.Holder(), info.GetIso late());
9870 TestObject* impl = V8TestObject::toImpl(info.Holder());
9871 int a;
9872 int b;
9873 {
9874 TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(a, toInt32(info[0], exceptionState ), exceptionState);
9875 TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(b, toInt32(info[1], exceptionState ), exceptionState);
9876 }
9877 impl->typeCheckingMaybeRedundantForOverloadingMethodsB(a, b);
9878 }
9879
9880 static void typeCheckingMaybeRedundantForOverloadingMethodsBMethod(const v8::Fun ctionCallbackInfo<v8::Value>& info)
9881 {
9882 ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckin gMaybeRedundantForOverloadingMethodsB", "TestObject", info.Holder(), info.GetIso late());
9883 switch (std::min(2, info.Length())) {
9884 case 1:
9885 if (true) {
9886 typeCheckingMaybeRedundantForOverloadingMethodsB1Method(info);
9887 return;
9888 }
9889 break;
9890 case 2:
9891 if (true) {
9892 typeCheckingMaybeRedundantForOverloadingMethodsB2Method(info);
9893 return;
9894 }
9895 break;
9896 default:
9897 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i nfo.Length()));
9898 exceptionState.throwIfNeeded();
9899 return;
9900 }
9901 exceptionState.throwTypeError("No function was found that matched the signat ure provided.");
9902 exceptionState.throwIfNeeded();
9903 }
9904
9905 static void typeCheckingMaybeRedundantForOverloadingMethodsBMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info)
9906 {
9907 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod");
9908 TestObjectV8Internal::typeCheckingMaybeRedundantForOverloadingMethodsBMethod (info);
9909 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
9910 }
9911
9912 static void typeCheckingMaybeRedundantForOverloadingMethodsC1Method(const v8::Fu nctionCallbackInfo<v8::Value>& info)
9913 {
9914 TestObject* impl = V8TestObject::toImpl(info.Holder());
9915 Node* a;
9916 {
9917 a = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
9918 }
9919 impl->typeCheckingMaybeRedundantForOverloadingMethodsC(a);
9920 }
9921
9922 static void typeCheckingMaybeRedundantForOverloadingMethodsC2Method(const v8::Fu nctionCallbackInfo<v8::Value>& info)
9923 {
9924 ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckin gMaybeRedundantForOverloadingMethodsC", "TestObject", info.Holder(), info.GetIso late());
9925 TestObject* impl = V8TestObject::toImpl(info.Holder());
9926 int a;
9927 int b;
9928 {
9929 TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(a, toInt32(info[0], exceptionState ), exceptionState);
9930 if (UNLIKELY(info.Length() <= 1)) {
9931 impl->typeCheckingMaybeRedundantForOverloadingMethodsC(a);
9932 return;
9933 }
9934 TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(b, toInt32(info[1], exceptionState ), exceptionState);
9935 }
9936 impl->typeCheckingMaybeRedundantForOverloadingMethodsC(a, b);
9937 }
9938
9939 static void typeCheckingMaybeRedundantForOverloadingMethodsCMethod(const v8::Fun ctionCallbackInfo<v8::Value>& info)
9940 {
9941 ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckin gMaybeRedundantForOverloadingMethodsC", "TestObject", info.Holder(), info.GetIso late());
9942 switch (std::min(2, info.Length())) {
9943 case 1:
9944 if (V8Node::hasInstance(info[0], info.GetIsolate())) {
9945 typeCheckingMaybeRedundantForOverloadingMethodsC1Method(info);
9946 return;
9947 }
9948 if (true) {
9949 typeCheckingMaybeRedundantForOverloadingMethodsC2Method(info);
9950 return;
9951 }
9952 break;
9953 case 2:
9954 if (true) {
9955 typeCheckingMaybeRedundantForOverloadingMethodsC2Method(info);
9956 return;
9957 }
9958 break;
9959 default:
9960 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i nfo.Length()));
9961 exceptionState.throwIfNeeded();
9962 return;
9963 }
9964 exceptionState.throwTypeError("No function was found that matched the signat ure provided.");
9965 exceptionState.throwIfNeeded();
9966 }
9967
9968 static void typeCheckingMaybeRedundantForOverloadingMethodsCMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info)
9969 {
9970 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod");
9971 TestObjectV8Internal::typeCheckingMaybeRedundantForOverloadingMethodsCMethod (info);
9972 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
9973 }
9974
9975 static void typeCheckingMaybeRedundantForOverloadingMethodsD1Method(const v8::Fu nctionCallbackInfo<v8::Value>& info)
9976 {
9977 TestObject* impl = V8TestObject::toImpl(info.Holder());
9978 Node* a;
9979 Node* b;
9980 {
9981 if (info.Length() > 0 && !V8Node::hasInstance(info[0], info.GetIsolate() )) {
9982 V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute( "typeCheckingMaybeRedundantForOverloadingMethodsD", "TestObject", "parameter 1 i s not of type 'Node'."), info.GetIsolate());
9983 return;
9984 }
9985 a = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
9986 b = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[1]));
9987 }
9988 impl->typeCheckingMaybeRedundantForOverloadingMethodsD(a, b);
9989 }
9990
9991 static void typeCheckingMaybeRedundantForOverloadingMethodsD2Method(const v8::Fu nctionCallbackInfo<v8::Value>& info)
9992 {
9993 ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckin gMaybeRedundantForOverloadingMethodsD", "TestObject", info.Holder(), info.GetIso late());
9994 TestObject* impl = V8TestObject::toImpl(info.Holder());
9995 Node* a;
9996 int b;
9997 {
9998 if (info.Length() > 0 && !V8Node::hasInstance(info[0], info.GetIsolate() )) {
9999 exceptionState.throwTypeError("parameter 1 is not of type 'Node'.");
10000 exceptionState.throwIfNeeded();
10001 return;
10002 }
10003 a = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
10004 TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(b, toInt32(info[1], exceptionState ), exceptionState);
10005 }
10006 impl->typeCheckingMaybeRedundantForOverloadingMethodsD(a, b);
10007 }
10008
10009 static void typeCheckingMaybeRedundantForOverloadingMethodsDMethod(const v8::Fun ctionCallbackInfo<v8::Value>& info)
10010 {
10011 ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckin gMaybeRedundantForOverloadingMethodsD", "TestObject", info.Holder(), info.GetIso late());
10012 switch (std::min(2, info.Length())) {
10013 case 2:
10014 if (V8Node::hasInstance(info[1], info.GetIsolate())) {
10015 typeCheckingMaybeRedundantForOverloadingMethodsD1Method(info);
10016 return;
10017 }
10018 if (true) {
10019 typeCheckingMaybeRedundantForOverloadingMethodsD2Method(info);
10020 return;
10021 }
10022 break;
10023 default:
10024 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(2, i nfo.Length()));
10025 exceptionState.throwIfNeeded();
10026 return;
10027 }
10028 exceptionState.throwTypeError("No function was found that matched the signat ure provided.");
10029 exceptionState.throwIfNeeded();
10030 }
10031
10032 static void typeCheckingMaybeRedundantForOverloadingMethodsDMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info)
10033 {
10034 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod");
10035 TestObjectV8Internal::typeCheckingMaybeRedundantForOverloadingMethodsDMethod (info);
10036 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
10037 }
10038
10039 static void typeCheckingMaybeRedundantForOverloadingMethodsE1Method(const v8::Fu nctionCallbackInfo<v8::Value>& info)
10040 {
10041 TestObject* impl = V8TestObject::toImpl(info.Holder());
10042 Node* a;
10043 Node* b;
10044 {
10045 if (info.Length() > 0 && !V8Node::hasInstance(info[0], info.GetIsolate() )) {
10046 V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute( "typeCheckingMaybeRedundantForOverloadingMethodsE", "TestObject", "parameter 1 i s not of type 'Node'."), info.GetIsolate());
10047 return;
10048 }
10049 a = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
10050 b = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[1]));
10051 }
10052 impl->typeCheckingMaybeRedundantForOverloadingMethodsE(a, b);
10053 }
10054
10055 static void typeCheckingMaybeRedundantForOverloadingMethodsE2Method(const v8::Fu nctionCallbackInfo<v8::Value>& info)
10056 {
10057 ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckin gMaybeRedundantForOverloadingMethodsE", "TestObject", info.Holder(), info.GetIso late());
10058 TestObject* impl = V8TestObject::toImpl(info.Holder());
10059 Node* a;
10060 int b;
10061 {
10062 if (info.Length() > 0 && !V8Node::hasInstance(info[0], info.GetIsolate() )) {
10063 exceptionState.throwTypeError("parameter 1 is not of type 'Node'.");
10064 exceptionState.throwIfNeeded();
10065 return;
10066 }
10067 a = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
10068 if (UNLIKELY(info.Length() <= 1)) {
10069 impl->typeCheckingMaybeRedundantForOverloadingMethodsE(a);
10070 return;
10071 }
10072 TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(b, toInt32(info[1], exceptionState ), exceptionState);
10073 }
10074 impl->typeCheckingMaybeRedundantForOverloadingMethodsE(a, b);
10075 }
10076
10077 static void typeCheckingMaybeRedundantForOverloadingMethodsEMethod(const v8::Fun ctionCallbackInfo<v8::Value>& info)
10078 {
10079 ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckin gMaybeRedundantForOverloadingMethodsE", "TestObject", info.Holder(), info.GetIso late());
10080 switch (std::min(2, info.Length())) {
10081 case 1:
10082 if (true) {
10083 typeCheckingMaybeRedundantForOverloadingMethodsE2Method(info);
10084 return;
10085 }
10086 break;
10087 case 2:
10088 if (info[1]->IsUndefined()) {
10089 typeCheckingMaybeRedundantForOverloadingMethodsE2Method(info);
10090 return;
10091 }
10092 if (V8Node::hasInstance(info[1], info.GetIsolate())) {
10093 typeCheckingMaybeRedundantForOverloadingMethodsE1Method(info);
10094 return;
10095 }
10096 if (true) {
10097 typeCheckingMaybeRedundantForOverloadingMethodsE2Method(info);
10098 return;
10099 }
10100 break;
10101 default:
10102 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i nfo.Length()));
10103 exceptionState.throwIfNeeded();
10104 return;
10105 }
10106 exceptionState.throwTypeError("No function was found that matched the signat ure provided.");
10107 exceptionState.throwIfNeeded();
10108 }
10109
10110 static void typeCheckingMaybeRedundantForOverloadingMethodsEMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info)
10111 {
10112 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod");
10113 TestObjectV8Internal::typeCheckingMaybeRedundantForOverloadingMethodsEMethod (info);
10114 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
10115 }
10116
10117 static void typeCheckingMaybeRedundantForOverloadingMethodsF1Method(const v8::Fu nctionCallbackInfo<v8::Value>& info)
10118 {
10119 TestObject* impl = V8TestObject::toImpl(info.Holder());
10120 Node* a;
10121 {
10122 if (UNLIKELY(info.Length() <= 0)) {
10123 impl->typeCheckingMaybeRedundantForOverloadingMethodsF();
10124 return;
10125 }
10126 if (info.Length() > 0 && !V8Node::hasInstance(info[0], info.GetIsolate() )) {
10127 V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute( "typeCheckingMaybeRedundantForOverloadingMethodsF", "TestObject", "parameter 1 i s not of type 'Node'."), info.GetIsolate());
10128 return;
10129 }
10130 a = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
10131 }
10132 impl->typeCheckingMaybeRedundantForOverloadingMethodsF(a);
10133 }
10134
10135 static void typeCheckingMaybeRedundantForOverloadingMethodsF2Method(const v8::Fu nctionCallbackInfo<v8::Value>& info)
10136 {
10137 TestObject* impl = V8TestObject::toImpl(info.Holder());
10138 Document* a;
10139 Node* b;
10140 {
10141 if (info.Length() > 0 && !V8Document::hasInstance(info[0], info.GetIsola te())) {
10142 V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute( "typeCheckingMaybeRedundantForOverloadingMethodsF", "TestObject", "parameter 1 i s not of type 'Document'."), info.GetIsolate());
10143 return;
10144 }
10145 a = V8Document::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
10146 if (UNLIKELY(info.Length() <= 1)) {
10147 impl->typeCheckingMaybeRedundantForOverloadingMethodsF(a);
10148 return;
10149 }
10150 if (info.Length() > 1 && !V8Node::hasInstance(info[1], info.GetIsolate() )) {
10151 V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute( "typeCheckingMaybeRedundantForOverloadingMethodsF", "TestObject", "parameter 2 i s not of type 'Node'."), info.GetIsolate());
10152 return;
10153 }
10154 b = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[1]));
10155 }
10156 impl->typeCheckingMaybeRedundantForOverloadingMethodsF(a, b);
10157 }
10158
10159 static void typeCheckingMaybeRedundantForOverloadingMethodsFMethod(const v8::Fun ctionCallbackInfo<v8::Value>& info)
10160 {
10161 ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckin gMaybeRedundantForOverloadingMethodsF", "TestObject", info.Holder(), info.GetIso late());
10162 switch (std::min(2, info.Length())) {
10163 case 0:
10164 if (true) {
10165 typeCheckingMaybeRedundantForOverloadingMethodsF1Method(info);
10166 return;
10167 }
10168 break;
10169 case 1:
10170 if (info[0]->IsUndefined()) {
10171 typeCheckingMaybeRedundantForOverloadingMethodsF1Method(info);
10172 return;
10173 }
10174 if (V8Node::hasInstance(info[0], info.GetIsolate())) {
10175 typeCheckingMaybeRedundantForOverloadingMethodsF1Method(info);
10176 return;
10177 }
10178 if (V8Document::hasInstance(info[0], info.GetIsolate())) {
10179 typeCheckingMaybeRedundantForOverloadingMethodsF2Method(info);
10180 return;
10181 }
10182 break;
10183 case 2:
10184 if (true) {
10185 typeCheckingMaybeRedundantForOverloadingMethodsF2Method(info);
10186 return;
10187 }
10188 break;
10189 default:
10190 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(0, i nfo.Length()));
10191 exceptionState.throwIfNeeded();
10192 return;
10193 }
10194 exceptionState.throwTypeError("No function was found that matched the signat ure provided.");
10195 exceptionState.throwIfNeeded();
10196 }
10197
10198 static void typeCheckingMaybeRedundantForOverloadingMethodsFMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info)
10199 {
10200 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod");
10201 TestObjectV8Internal::typeCheckingMaybeRedundantForOverloadingMethodsFMethod (info);
10202 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
10203 }
10204
9797 static void typeCheckingUnrestrictedVoidMethodFloatArgDoubleArgMethod(const v8:: FunctionCallbackInfo<v8::Value>& info) 10205 static void typeCheckingUnrestrictedVoidMethodFloatArgDoubleArgMethod(const v8:: FunctionCallbackInfo<v8::Value>& info)
9798 { 10206 {
9799 ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckin gUnrestrictedVoidMethodFloatArgDoubleArg", "TestObject", info.Holder(), info.Get Isolate()); 10207 ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckin gUnrestrictedVoidMethodFloatArgDoubleArg", "TestObject", info.Holder(), info.Get Isolate());
9800 if (UNLIKELY(info.Length() < 2)) { 10208 if (UNLIKELY(info.Length() < 2)) {
9801 setMinimumArityTypeError(exceptionState, 2, info.Length()); 10209 setMinimumArityTypeError(exceptionState, 2, info.Length());
9802 exceptionState.throwIfNeeded(); 10210 exceptionState.throwIfNeeded();
9803 return; 10211 return;
9804 } 10212 }
9805 TestObject* impl = V8TestObject::toImpl(info.Holder()); 10213 TestObject* impl = V8TestObject::toImpl(info.Holder());
9806 float floatArg; 10214 float floatArg;
(...skipping 658 matching lines...) Expand 10 before | Expand all | Expand 10 after
10465 {"treatReturnedNullStringAsUndefinedStringMethod", TestObjectV8Internal::tre atReturnedNullStringAsUndefinedStringMethodMethodCallback, 0, 0, V8DOMConfigurat ion::ExposedToAllScripts}, 10873 {"treatReturnedNullStringAsUndefinedStringMethod", TestObjectV8Internal::tre atReturnedNullStringAsUndefinedStringMethodMethodCallback, 0, 0, V8DOMConfigurat ion::ExposedToAllScripts},
10466 {"treatReturnedNullStringAsNullByteStringMethod", TestObjectV8Internal::trea tReturnedNullStringAsNullByteStringMethodMethodCallback, 0, 0, V8DOMConfiguratio n::ExposedToAllScripts}, 10874 {"treatReturnedNullStringAsNullByteStringMethod", TestObjectV8Internal::trea tReturnedNullStringAsNullByteStringMethodMethodCallback, 0, 0, V8DOMConfiguratio n::ExposedToAllScripts},
10467 {"treatReturnedNullStringAsUndefinedByteStringMethod", TestObjectV8Internal: :treatReturnedNullStringAsUndefinedByteStringMethodMethodCallback, 0, 0, V8DOMCo nfiguration::ExposedToAllScripts}, 10875 {"treatReturnedNullStringAsUndefinedByteStringMethod", TestObjectV8Internal: :treatReturnedNullStringAsUndefinedByteStringMethodMethodCallback, 0, 0, V8DOMCo nfiguration::ExposedToAllScripts},
10468 {"treatReturnedNullStringAsNullScalarValueStringMethod", TestObjectV8Interna l::treatReturnedNullStringAsNullScalarValueStringMethodMethodCallback, 0, 0, V8D OMConfiguration::ExposedToAllScripts}, 10876 {"treatReturnedNullStringAsNullScalarValueStringMethod", TestObjectV8Interna l::treatReturnedNullStringAsNullScalarValueStringMethodMethodCallback, 0, 0, V8D OMConfiguration::ExposedToAllScripts},
10469 {"treatReturnedNullStringAsUndefinedScalarValueStringMethod", TestObjectV8In ternal::treatReturnedNullStringAsUndefinedScalarValueStringMethodMethodCallback, 0, 0, V8DOMConfiguration::ExposedToAllScripts}, 10877 {"treatReturnedNullStringAsUndefinedScalarValueStringMethod", TestObjectV8In ternal::treatReturnedNullStringAsUndefinedScalarValueStringMethodMethodCallback, 0, 0, V8DOMConfiguration::ExposedToAllScripts},
10470 {"typeCheckingInterfaceVoidMethodTestInterfaceEmptyArg", TestObjectV8Interna l::typeCheckingInterfaceVoidMethodTestInterfaceEmptyArgMethodCallback, 0, 1, V8D OMConfiguration::ExposedToAllScripts}, 10878 {"typeCheckingInterfaceVoidMethodTestInterfaceEmptyArg", TestObjectV8Interna l::typeCheckingInterfaceVoidMethodTestInterfaceEmptyArgMethodCallback, 0, 1, V8D OMConfiguration::ExposedToAllScripts},
10471 {"typeCheckingInterfaceVoidMethodTestInterfaceEmptyVariadicArg", TestObjectV 8Internal::typeCheckingInterfaceVoidMethodTestInterfaceEmptyVariadicArgMethodCal lback, 0, 0, V8DOMConfiguration::ExposedToAllScripts}, 10879 {"typeCheckingInterfaceVoidMethodTestInterfaceEmptyVariadicArg", TestObjectV 8Internal::typeCheckingInterfaceVoidMethodTestInterfaceEmptyVariadicArgMethodCal lback, 0, 0, V8DOMConfiguration::ExposedToAllScripts},
10472 {"useToImpl4ArgumentsCheckingIfPossibleWithOptionalArg", TestObjectV8Interna l::useToImpl4ArgumentsCheckingIfPossibleWithOptionalArgMethodCallback, 0, 1, V8D OMConfiguration::ExposedToAllScripts}, 10880 {"useToImpl4ArgumentsCheckingIfPossibleWithOptionalArg", TestObjectV8Interna l::useToImpl4ArgumentsCheckingIfPossibleWithOptionalArgMethodCallback, 0, 1, V8D OMConfiguration::ExposedToAllScripts},
10473 {"useToImpl4ArgumentsCheckingIfPossibleWithNullableArg", TestObjectV8Interna l::useToImpl4ArgumentsCheckingIfPossibleWithNullableArgMethodCallback, 0, 2, V8D OMConfiguration::ExposedToAllScripts}, 10881 {"useToImpl4ArgumentsCheckingIfPossibleWithNullableArg", TestObjectV8Interna l::useToImpl4ArgumentsCheckingIfPossibleWithNullableArgMethodCallback, 0, 2, V8D OMConfiguration::ExposedToAllScripts},
10474 {"useToImpl4ArgumentsCheckingIfPossibleWithUndefinedArg", TestObjectV8Intern al::useToImpl4ArgumentsCheckingIfPossibleWithUndefinedArgMethodCallback, 0, 1, V 8DOMConfiguration::ExposedToAllScripts}, 10882 {"useToImpl4ArgumentsCheckingIfPossibleWithUndefinedArg", TestObjectV8Intern al::useToImpl4ArgumentsCheckingIfPossibleWithUndefinedArgMethodCallback, 0, 1, V 8DOMConfiguration::ExposedToAllScripts},
10883 {"typeCheckingMaybeRedundantForOverloadingMethodsA", TestObjectV8Internal::t ypeCheckingMaybeRedundantForOverloadingMethodsAMethodCallback, 0, 2, V8DOMConfig uration::ExposedToAllScripts},
10884 {"typeCheckingMaybeRedundantForOverloadingMethodsB", TestObjectV8Internal::t ypeCheckingMaybeRedundantForOverloadingMethodsBMethodCallback, 0, 1, V8DOMConfig uration::ExposedToAllScripts},
10885 {"typeCheckingMaybeRedundantForOverloadingMethodsC", TestObjectV8Internal::t ypeCheckingMaybeRedundantForOverloadingMethodsCMethodCallback, 0, 1, V8DOMConfig uration::ExposedToAllScripts},
10886 {"typeCheckingMaybeRedundantForOverloadingMethodsD", TestObjectV8Internal::t ypeCheckingMaybeRedundantForOverloadingMethodsDMethodCallback, 0, 2, V8DOMConfig uration::ExposedToAllScripts},
10887 {"typeCheckingMaybeRedundantForOverloadingMethodsE", TestObjectV8Internal::t ypeCheckingMaybeRedundantForOverloadingMethodsEMethodCallback, 0, 1, V8DOMConfig uration::ExposedToAllScripts},
10888 {"typeCheckingMaybeRedundantForOverloadingMethodsF", TestObjectV8Internal::t ypeCheckingMaybeRedundantForOverloadingMethodsFMethodCallback, 0, 0, V8DOMConfig uration::ExposedToAllScripts},
10475 {"typeCheckingUnrestrictedVoidMethodFloatArgDoubleArg", TestObjectV8Internal ::typeCheckingUnrestrictedVoidMethodFloatArgDoubleArgMethodCallback, 0, 2, V8DOM Configuration::ExposedToAllScripts}, 10889 {"typeCheckingUnrestrictedVoidMethodFloatArgDoubleArg", TestObjectV8Internal ::typeCheckingUnrestrictedVoidMethodFloatArgDoubleArgMethodCallback, 0, 2, V8DOM Configuration::ExposedToAllScripts},
10476 {"voidMethodTestInterfaceGarbageCollectedSequenceArg", TestObjectV8Internal: :voidMethodTestInterfaceGarbageCollectedSequenceArgMethodCallback, 0, 1, V8DOMCo nfiguration::ExposedToAllScripts}, 10890 {"voidMethodTestInterfaceGarbageCollectedSequenceArg", TestObjectV8Internal: :voidMethodTestInterfaceGarbageCollectedSequenceArgMethodCallback, 0, 1, V8DOMCo nfiguration::ExposedToAllScripts},
10477 {"voidMethodTestInterfaceGarbageCollectedArrayArg", TestObjectV8Internal::vo idMethodTestInterfaceGarbageCollectedArrayArgMethodCallback, 0, 1, V8DOMConfigur ation::ExposedToAllScripts}, 10891 {"voidMethodTestInterfaceGarbageCollectedArrayArg", TestObjectV8Internal::vo idMethodTestInterfaceGarbageCollectedArrayArgMethodCallback, 0, 1, V8DOMConfigur ation::ExposedToAllScripts},
10478 {"voidMethodTestInterfaceWillBeGarbageCollectedSequenceArg", TestObjectV8Int ernal::voidMethodTestInterfaceWillBeGarbageCollectedSequenceArgMethodCallback, 0 , 1, V8DOMConfiguration::ExposedToAllScripts}, 10892 {"voidMethodTestInterfaceWillBeGarbageCollectedSequenceArg", TestObjectV8Int ernal::voidMethodTestInterfaceWillBeGarbageCollectedSequenceArgMethodCallback, 0 , 1, V8DOMConfiguration::ExposedToAllScripts},
10479 {"voidMethodTestInterfaceWillBeGarbageCollectedArrayArg", TestObjectV8Intern al::voidMethodTestInterfaceWillBeGarbageCollectedArrayArgMethodCallback, 0, 1, V 8DOMConfiguration::ExposedToAllScripts}, 10893 {"voidMethodTestInterfaceWillBeGarbageCollectedArrayArg", TestObjectV8Intern al::voidMethodTestInterfaceWillBeGarbageCollectedArrayArgMethodCallback, 0, 1, V 8DOMConfiguration::ExposedToAllScripts},
10480 {"voidMethodImplementedInPrivateScript", TestObjectV8Internal::voidMethodImp lementedInPrivateScriptMethodCallback, 0, 0, V8DOMConfiguration::ExposedToAllScr ipts}, 10894 {"voidMethodImplementedInPrivateScript", TestObjectV8Internal::voidMethodImp lementedInPrivateScriptMethodCallback, 0, 0, V8DOMConfiguration::ExposedToAllScr ipts},
10481 {"shortMethodImplementedInPrivateScript", TestObjectV8Internal::shortMethodI mplementedInPrivateScriptMethodCallback, 0, 0, V8DOMConfiguration::ExposedToAllS cripts}, 10895 {"shortMethodImplementedInPrivateScript", TestObjectV8Internal::shortMethodI mplementedInPrivateScriptMethodCallback, 0, 0, V8DOMConfiguration::ExposedToAllS cripts},
10482 {"shortMethodWithShortArgumentImplementedInPrivateScript", TestObjectV8Inter nal::shortMethodWithShortArgumentImplementedInPrivateScriptMethodCallback, 0, 1, V8DOMConfiguration::ExposedToAllScripts}, 10896 {"shortMethodWithShortArgumentImplementedInPrivateScript", TestObjectV8Inter nal::shortMethodWithShortArgumentImplementedInPrivateScriptMethodCallback, 0, 1, V8DOMConfiguration::ExposedToAllScripts},
10483 {"stringMethodWithStringArgumentImplementedInPrivateScript", TestObjectV8Int ernal::stringMethodWithStringArgumentImplementedInPrivateScriptMethodCallback, 0 , 1, V8DOMConfiguration::ExposedToAllScripts}, 10897 {"stringMethodWithStringArgumentImplementedInPrivateScript", TestObjectV8Int ernal::stringMethodWithStringArgumentImplementedInPrivateScriptMethodCallback, 0 , 1, V8DOMConfiguration::ExposedToAllScripts},
10484 {"nodeMethodWithNodeArgumentImplementedInPrivateScript", TestObjectV8Interna l::nodeMethodWithNodeArgumentImplementedInPrivateScriptMethodCallback, 0, 1, V8D OMConfiguration::ExposedToAllScripts}, 10898 {"nodeMethodWithNodeArgumentImplementedInPrivateScript", TestObjectV8Interna l::nodeMethodWithNodeArgumentImplementedInPrivateScriptMethodCallback, 0, 1, V8D OMConfiguration::ExposedToAllScripts},
(...skipping 666 matching lines...) Expand 10 before | Expand all | Expand 10 after
11151 return false; 11565 return false;
11152 11566
11153 ScriptState::Scope scope(scriptState); 11567 ScriptState::Scope scope(scriptState);
11154 v8::Handle<v8::Value> holder = toV8(holderImpl, scriptState->context()->Glob al(), scriptState->isolate()); 11568 v8::Handle<v8::Value> holder = toV8(holderImpl, scriptState->context()->Glob al(), scriptState->isolate());
11155 11569
11156 ExceptionState exceptionState(ExceptionState::SetterContext, "enumForPrivate Script", "TestObject", scriptState->context()->Global(), scriptState->isolate()) ; 11570 ExceptionState exceptionState(ExceptionState::SetterContext, "enumForPrivate Script", "TestObject", scriptState->context()->Global(), scriptState->isolate()) ;
11157 return PrivateScriptRunner::runDOMAttributeSetter(scriptState, scriptStateIn UserScript, "TestObject", "enumForPrivateScript", holder, v8String(scriptState-> isolate(), cppValue)); 11571 return PrivateScriptRunner::runDOMAttributeSetter(scriptState, scriptStateIn UserScript, "TestObject", "enumForPrivateScript", holder, v8String(scriptState-> isolate(), cppValue));
11158 } 11572 }
11159 11573
11160 } // namespace blink 11574 } // namespace blink
OLDNEW
« no previous file with comments | « Source/bindings/tests/idls/core/TestObject.idl ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698