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

Unified Diff: Source/bindings/tests/results/core/V8TestObject.cpp

Issue 657523002: Skip expensive hasInstance() type-checks in overloads (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: minor updates 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 side-by-side diff with in-line comments
Download patch
Index: Source/bindings/tests/results/core/V8TestObject.cpp
diff --git a/Source/bindings/tests/results/core/V8TestObject.cpp b/Source/bindings/tests/results/core/V8TestObject.cpp
index c2ce1858fd9fd1968886a20136d6174ab85de177..1097a6e7060b8572d2f3ae1bc582f60a633a9165 100644
--- a/Source/bindings/tests/results/core/V8TestObject.cpp
+++ b/Source/bindings/tests/results/core/V8TestObject.cpp
@@ -6792,7 +6792,7 @@ static void voidMethodDictionarySequenceArgMethodCallback(const v8::FunctionCall
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void overloadedPromiseMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedPromiseMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedPromiseMethod", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -6803,7 +6803,7 @@ static void overloadedPromiseMethod1Method(const v8::FunctionCallbackInfo<v8::Va
v8SetReturnValue(info, impl->overloadedPromiseMethod(arg).v8Value());
}
-static void overloadedPromiseMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedPromiseMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedPromiseMethod", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -6820,15 +6820,15 @@ static void overloadedPromiseMethodMethod(const v8::FunctionCallbackInfo<v8::Val
switch (std::min(1, info.Length())) {
case 1:
if (info[0]->IsNumber()) {
- overloadedPromiseMethod1Method(info);
+ overloadedPromiseMethod1Method(info, 0);
return;
}
if (true) {
- overloadedPromiseMethod2Method(info);
+ overloadedPromiseMethod2Method(info, -1);
return;
}
if (true) {
- overloadedPromiseMethod1Method(info);
+ overloadedPromiseMethod1Method(info, -1);
return;
}
break;
@@ -7501,7 +7501,7 @@ static void voidMethodVariadicTestInterfaceWillBeGarbageCollectedArgMethodCallba
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void overloadedMethodA1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodA1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedMethodA", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -7512,7 +7512,7 @@ static void overloadedMethodA1Method(const v8::FunctionCallbackInfo<v8::Value>&
impl->overloadedMethodA(longArg);
}
-static void overloadedMethodA2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodA2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedMethodA", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -7531,13 +7531,13 @@ static void overloadedMethodAMethod(const v8::FunctionCallbackInfo<v8::Value>& i
switch (std::min(2, info.Length())) {
case 1:
if (true) {
- overloadedMethodA1Method(info);
+ overloadedMethodA1Method(info, -1);
return;
}
break;
case 2:
if (true) {
- overloadedMethodA2Method(info);
+ overloadedMethodA2Method(info, -1);
return;
}
break;
@@ -7557,7 +7557,7 @@ static void overloadedMethodAMethodCallback(const v8::FunctionCallbackInfo<v8::V
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void overloadedMethodB1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodB1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedMethodB", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -7568,7 +7568,7 @@ static void overloadedMethodB1Method(const v8::FunctionCallbackInfo<v8::Value>&
impl->overloadedMethodB(longArg);
}
-static void overloadedMethodB2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodB2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedMethodB", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -7591,21 +7591,21 @@ static void overloadedMethodBMethod(const v8::FunctionCallbackInfo<v8::Value>& i
switch (std::min(2, info.Length())) {
case 1:
if (info[0]->IsNumber()) {
- overloadedMethodB1Method(info);
+ overloadedMethodB1Method(info, 0);
return;
}
if (true) {
- overloadedMethodB2Method(info);
+ overloadedMethodB2Method(info, -1);
return;
}
if (true) {
- overloadedMethodB1Method(info);
+ overloadedMethodB1Method(info, -1);
return;
}
break;
case 2:
if (true) {
- overloadedMethodB2Method(info);
+ overloadedMethodB2Method(info, -1);
return;
}
break;
@@ -7625,7 +7625,7 @@ static void overloadedMethodBMethodCallback(const v8::FunctionCallbackInfo<v8::V
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void overloadedMethodC1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodC1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedMethodC", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -7636,12 +7636,15 @@ static void overloadedMethodC1Method(const v8::FunctionCallbackInfo<v8::Value>&
impl->overloadedMethodC(longArg);
}
-static void overloadedMethodC2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodC2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
TestInterfaceEmpty* testInterfaceEmptyArg;
{
- testInterfaceEmptyArg = V8TestInterfaceEmpty::toImplWithTypeCheck(info.GetIsolate(), info[0]);
+ if (typeCheckedArgumentIndex == 0)
+ testInterfaceEmptyArg = V8TestInterfaceEmpty::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
+ else
+ testInterfaceEmptyArg = V8TestInterfaceEmpty::toImplWithTypeCheck(info.GetIsolate(), info[0]);
}
impl->overloadedMethodC(testInterfaceEmptyArg);
}
@@ -7652,11 +7655,11 @@ static void overloadedMethodCMethod(const v8::FunctionCallbackInfo<v8::Value>& i
switch (std::min(1, info.Length())) {
case 1:
if (V8TestInterfaceEmpty::hasInstance(info[0], info.GetIsolate())) {
- overloadedMethodC2Method(info);
+ overloadedMethodC2Method(info, 0);
return;
}
if (true) {
- overloadedMethodC1Method(info);
+ overloadedMethodC1Method(info, -1);
return;
}
break;
@@ -7676,7 +7679,7 @@ static void overloadedMethodCMethodCallback(const v8::FunctionCallbackInfo<v8::V
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void overloadedMethodD1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodD1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedMethodD", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -7687,7 +7690,7 @@ static void overloadedMethodD1Method(const v8::FunctionCallbackInfo<v8::Value>&
impl->overloadedMethodD(longArg);
}
-static void overloadedMethodD2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodD2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedMethodD", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -7704,11 +7707,11 @@ static void overloadedMethodDMethod(const v8::FunctionCallbackInfo<v8::Value>& i
switch (std::min(1, info.Length())) {
case 1:
if (info[0]->IsArray()) {
- overloadedMethodD2Method(info);
+ overloadedMethodD2Method(info, 0);
return;
}
if (true) {
- overloadedMethodD1Method(info);
+ overloadedMethodD1Method(info, -1);
return;
}
break;
@@ -7728,7 +7731,7 @@ static void overloadedMethodDMethodCallback(const v8::FunctionCallbackInfo<v8::V
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void overloadedMethodE1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodE1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedMethodE", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -7739,12 +7742,15 @@ static void overloadedMethodE1Method(const v8::FunctionCallbackInfo<v8::Value>&
impl->overloadedMethodE(longArg);
}
-static void overloadedMethodE2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodE2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
TestInterfaceEmpty* testInterfaceEmptyOrNullArg;
{
- testInterfaceEmptyOrNullArg = V8TestInterfaceEmpty::toImplWithTypeCheck(info.GetIsolate(), info[0]);
+ if (typeCheckedArgumentIndex == 0)
+ testInterfaceEmptyOrNullArg = V8TestInterfaceEmpty::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
+ else
+ testInterfaceEmptyOrNullArg = V8TestInterfaceEmpty::toImplWithTypeCheck(info.GetIsolate(), info[0]);
}
impl->overloadedMethodE(testInterfaceEmptyOrNullArg);
}
@@ -7755,15 +7761,15 @@ static void overloadedMethodEMethod(const v8::FunctionCallbackInfo<v8::Value>& i
switch (std::min(1, info.Length())) {
case 1:
if (isUndefinedOrNull(info[0])) {
- overloadedMethodE2Method(info);
+ overloadedMethodE2Method(info, -1);
return;
}
if (V8TestInterfaceEmpty::hasInstance(info[0], info.GetIsolate())) {
- overloadedMethodE2Method(info);
+ overloadedMethodE2Method(info, 0);
return;
}
if (true) {
- overloadedMethodE1Method(info);
+ overloadedMethodE1Method(info, -1);
return;
}
break;
@@ -7783,7 +7789,7 @@ static void overloadedMethodEMethodCallback(const v8::FunctionCallbackInfo<v8::V
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void overloadedMethodF1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodF1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
V8StringResource<> stringArg;
@@ -7797,7 +7803,7 @@ static void overloadedMethodF1Method(const v8::FunctionCallbackInfo<v8::Value>&
impl->overloadedMethodF(stringArg);
}
-static void overloadedMethodF2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodF2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedMethodF", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -7814,25 +7820,25 @@ static void overloadedMethodFMethod(const v8::FunctionCallbackInfo<v8::Value>& i
switch (std::min(1, info.Length())) {
case 0:
if (true) {
- overloadedMethodF1Method(info);
+ overloadedMethodF1Method(info, -1);
return;
}
break;
case 1:
if (info[0]->IsUndefined()) {
- overloadedMethodF1Method(info);
+ overloadedMethodF1Method(info, -1);
return;
}
if (info[0]->IsNumber()) {
- overloadedMethodF2Method(info);
+ overloadedMethodF2Method(info, 0);
return;
}
if (true) {
- overloadedMethodF1Method(info);
+ overloadedMethodF1Method(info, -1);
return;
}
if (true) {
- overloadedMethodF2Method(info);
+ overloadedMethodF2Method(info, -1);
return;
}
break;
@@ -7852,7 +7858,7 @@ static void overloadedMethodFMethodCallback(const v8::FunctionCallbackInfo<v8::V
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void overloadedMethodG1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodG1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedMethodG", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -7863,13 +7869,16 @@ static void overloadedMethodG1Method(const v8::FunctionCallbackInfo<v8::Value>&
impl->overloadedMethodG(longArg);
}
-static void overloadedMethodG2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodG2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
TestInterfaceEmpty* testInterfaceEmptyOrNullArg;
{
if (!info[0]->IsUndefined()) {
- testInterfaceEmptyOrNullArg = V8TestInterfaceEmpty::toImplWithTypeCheck(info.GetIsolate(), info[0]);
+ if (typeCheckedArgumentIndex == 0)
+ testInterfaceEmptyOrNullArg = V8TestInterfaceEmpty::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
+ else
+ testInterfaceEmptyOrNullArg = V8TestInterfaceEmpty::toImplWithTypeCheck(info.GetIsolate(), info[0]);
} else {
testInterfaceEmptyOrNullArg = nullptr;
}
@@ -7883,25 +7892,25 @@ static void overloadedMethodGMethod(const v8::FunctionCallbackInfo<v8::Value>& i
switch (std::min(1, info.Length())) {
case 0:
if (true) {
- overloadedMethodG2Method(info);
+ overloadedMethodG2Method(info, -1);
return;
}
break;
case 1:
if (info[0]->IsUndefined()) {
- overloadedMethodG2Method(info);
+ overloadedMethodG2Method(info, -1);
return;
}
if (isUndefinedOrNull(info[0])) {
- overloadedMethodG2Method(info);
+ overloadedMethodG2Method(info, -1);
return;
}
if (V8TestInterfaceEmpty::hasInstance(info[0], info.GetIsolate())) {
- overloadedMethodG2Method(info);
+ overloadedMethodG2Method(info, 0);
return;
}
if (true) {
- overloadedMethodG1Method(info);
+ overloadedMethodG1Method(info, -1);
return;
}
break;
@@ -7921,22 +7930,28 @@ static void overloadedMethodGMethodCallback(const v8::FunctionCallbackInfo<v8::V
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void overloadedMethodH1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodH1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
TestInterfaceImplementation* testInterfaceArg;
{
- testInterfaceArg = V8TestInterface::toImplWithTypeCheck(info.GetIsolate(), info[0]);
+ if (typeCheckedArgumentIndex == 0)
+ testInterfaceArg = V8TestInterface::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
+ else
+ testInterfaceArg = V8TestInterface::toImplWithTypeCheck(info.GetIsolate(), info[0]);
}
impl->overloadedMethodH(testInterfaceArg);
}
-static void overloadedMethodH2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodH2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
TestInterfaceEmpty* testInterfaceEmptyArg;
{
- testInterfaceEmptyArg = V8TestInterfaceEmpty::toImplWithTypeCheck(info.GetIsolate(), info[0]);
+ if (typeCheckedArgumentIndex == 0)
+ testInterfaceEmptyArg = V8TestInterfaceEmpty::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
+ else
+ testInterfaceEmptyArg = V8TestInterfaceEmpty::toImplWithTypeCheck(info.GetIsolate(), info[0]);
}
impl->overloadedMethodH(testInterfaceEmptyArg);
}
@@ -7947,11 +7962,11 @@ static void overloadedMethodHMethod(const v8::FunctionCallbackInfo<v8::Value>& i
switch (std::min(1, info.Length())) {
case 1:
if (V8TestInterface::hasInstance(info[0], info.GetIsolate())) {
- overloadedMethodH1Method(info);
+ overloadedMethodH1Method(info, 0);
return;
}
if (V8TestInterfaceEmpty::hasInstance(info[0], info.GetIsolate())) {
- overloadedMethodH2Method(info);
+ overloadedMethodH2Method(info, 0);
return;
}
break;
@@ -7971,7 +7986,7 @@ static void overloadedMethodHMethodCallback(const v8::FunctionCallbackInfo<v8::V
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void overloadedMethodI1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodI1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
V8StringResource<> stringArg;
@@ -7981,7 +7996,7 @@ static void overloadedMethodI1Method(const v8::FunctionCallbackInfo<v8::Value>&
impl->overloadedMethodI(stringArg);
}
-static void overloadedMethodI2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodI2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedMethodI", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -7998,15 +8013,15 @@ static void overloadedMethodIMethod(const v8::FunctionCallbackInfo<v8::Value>& i
switch (std::min(1, info.Length())) {
case 1:
if (info[0]->IsNumber()) {
- overloadedMethodI2Method(info);
+ overloadedMethodI2Method(info, 0);
return;
}
if (true) {
- overloadedMethodI1Method(info);
+ overloadedMethodI1Method(info, -1);
return;
}
if (true) {
- overloadedMethodI2Method(info);
+ overloadedMethodI2Method(info, -1);
return;
}
break;
@@ -8026,7 +8041,7 @@ static void overloadedMethodIMethodCallback(const v8::FunctionCallbackInfo<v8::V
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void overloadedMethodJ1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodJ1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
V8StringResource<> stringArg;
@@ -8036,7 +8051,7 @@ static void overloadedMethodJ1Method(const v8::FunctionCallbackInfo<v8::Value>&
impl->overloadedMethodJ(stringArg);
}
-static void overloadedMethodJ2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedMethodJ2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedMethodJ", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -8062,11 +8077,11 @@ static void overloadedMethodJMethod(const v8::FunctionCallbackInfo<v8::Value>& i
switch (std::min(1, info.Length())) {
case 1:
if (info[0]->IsObject()) {
- overloadedMethodJ2Method(info);
+ overloadedMethodJ2Method(info, 0);
return;
}
if (true) {
- overloadedMethodJ1Method(info);
+ overloadedMethodJ1Method(info, -1);
return;
}
break;
@@ -8086,19 +8101,19 @@ static void overloadedMethodJMethodCallback(const v8::FunctionCallbackInfo<v8::V
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void overloadedPerWorldBindingsMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedPerWorldBindingsMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
impl->overloadedPerWorldBindingsMethod();
}
-static void overloadedPerWorldBindingsMethod1MethodForMainWorld(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedPerWorldBindingsMethod1MethodForMainWorld(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
impl->overloadedPerWorldBindingsMethod();
}
-static void overloadedPerWorldBindingsMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedPerWorldBindingsMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedPerWorldBindingsMethod", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -8115,13 +8130,13 @@ static void overloadedPerWorldBindingsMethodMethod(const v8::FunctionCallbackInf
switch (std::min(1, info.Length())) {
case 0:
if (true) {
- overloadedPerWorldBindingsMethod1Method(info);
+ overloadedPerWorldBindingsMethod1Method(info, -1);
return;
}
break;
case 1:
if (true) {
- overloadedPerWorldBindingsMethod2Method(info);
+ overloadedPerWorldBindingsMethod2Method(info, -1);
return;
}
break;
@@ -8141,7 +8156,7 @@ static void overloadedPerWorldBindingsMethodMethodCallback(const v8::FunctionCal
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void overloadedPerWorldBindingsMethod2MethodForMainWorld(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedPerWorldBindingsMethod2MethodForMainWorld(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedPerWorldBindingsMethod", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -8158,13 +8173,13 @@ static void overloadedPerWorldBindingsMethodMethodForMainWorld(const v8::Functio
switch (std::min(1, info.Length())) {
case 0:
if (true) {
- overloadedPerWorldBindingsMethod1MethodForMainWorld(info);
+ overloadedPerWorldBindingsMethod1MethodForMainWorld(info, -1);
return;
}
break;
case 1:
if (true) {
- overloadedPerWorldBindingsMethod2MethodForMainWorld(info);
+ overloadedPerWorldBindingsMethod2MethodForMainWorld(info, -1);
return;
}
break;
@@ -8184,7 +8199,7 @@ static void overloadedPerWorldBindingsMethodMethodCallbackForMainWorld(const v8:
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void overloadedStaticMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedStaticMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedStaticMethod", "TestObject", info.Holder(), info.GetIsolate());
int longArg;
@@ -8194,7 +8209,7 @@ static void overloadedStaticMethod1Method(const v8::FunctionCallbackInfo<v8::Val
TestObject::overloadedStaticMethod(longArg);
}
-static void overloadedStaticMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void overloadedStaticMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedStaticMethod", "TestObject", info.Holder(), info.GetIsolate());
int longArg1;
@@ -8212,13 +8227,13 @@ static void overloadedStaticMethodMethod(const v8::FunctionCallbackInfo<v8::Valu
switch (std::min(2, info.Length())) {
case 1:
if (true) {
- overloadedStaticMethod1Method(info);
+ overloadedStaticMethod1Method(info, -1);
return;
}
break;
case 2:
if (true) {
- overloadedStaticMethod2Method(info);
+ overloadedStaticMethod2Method(info, -1);
return;
}
break;
@@ -8701,13 +8716,13 @@ static void measureAsVoidMethodMethodCallback(const v8::FunctionCallbackInfo<v8:
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void DeprecateAsOverloadedMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void DeprecateAsOverloadedMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
impl->DeprecateAsOverloadedMethod();
}
-static void DeprecateAsOverloadedMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void DeprecateAsOverloadedMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "DeprecateAsOverloadedMethod", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -8725,14 +8740,14 @@ static void DeprecateAsOverloadedMethodMethod(const v8::FunctionCallbackInfo<v8:
case 0:
if (true) {
UseCounter::countDeprecation(callingExecutionContext(info.GetIsolate()), UseCounter::TestFeatureA);
- DeprecateAsOverloadedMethod1Method(info);
+ DeprecateAsOverloadedMethod1Method(info, -1);
return;
}
break;
case 1:
if (true) {
UseCounter::countDeprecation(callingExecutionContext(info.GetIsolate()), UseCounter::TestFeatureB);
- DeprecateAsOverloadedMethod2Method(info);
+ DeprecateAsOverloadedMethod2Method(info, -1);
return;
}
break;
@@ -8752,13 +8767,13 @@ static void DeprecateAsOverloadedMethodMethodCallback(const v8::FunctionCallback
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void DeprecateAsSameValueOverloadedMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void DeprecateAsSameValueOverloadedMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
impl->DeprecateAsSameValueOverloadedMethod();
}
-static void DeprecateAsSameValueOverloadedMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void DeprecateAsSameValueOverloadedMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "DeprecateAsSameValueOverloadedMethod", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -8776,13 +8791,13 @@ static void DeprecateAsSameValueOverloadedMethodMethod(const v8::FunctionCallbac
switch (std::min(1, info.Length())) {
case 0:
if (true) {
- DeprecateAsSameValueOverloadedMethod1Method(info);
+ DeprecateAsSameValueOverloadedMethod1Method(info, -1);
return;
}
break;
case 1:
if (true) {
- DeprecateAsSameValueOverloadedMethod2Method(info);
+ DeprecateAsSameValueOverloadedMethod2Method(info, -1);
return;
}
break;
@@ -8802,13 +8817,13 @@ static void DeprecateAsSameValueOverloadedMethodMethodCallback(const v8::Functio
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void measureAsOverloadedMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void measureAsOverloadedMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
impl->measureAsOverloadedMethod();
}
-static void measureAsOverloadedMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void measureAsOverloadedMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "measureAsOverloadedMethod", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -8826,14 +8841,14 @@ static void measureAsOverloadedMethodMethod(const v8::FunctionCallbackInfo<v8::V
case 0:
if (true) {
UseCounter::count(callingExecutionContext(info.GetIsolate()), UseCounter::TestFeatureA);
- measureAsOverloadedMethod1Method(info);
+ measureAsOverloadedMethod1Method(info, -1);
return;
}
break;
case 1:
if (true) {
UseCounter::count(callingExecutionContext(info.GetIsolate()), UseCounter::TestFeatureB);
- measureAsOverloadedMethod2Method(info);
+ measureAsOverloadedMethod2Method(info, -1);
return;
}
break;
@@ -8853,13 +8868,13 @@ static void measureAsOverloadedMethodMethodCallback(const v8::FunctionCallbackIn
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void measureAsSameValueOverloadedMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void measureAsSameValueOverloadedMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
impl->measureAsSameValueOverloadedMethod();
}
-static void measureAsSameValueOverloadedMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void measureAsSameValueOverloadedMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "measureAsSameValueOverloadedMethod", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -8877,13 +8892,13 @@ static void measureAsSameValueOverloadedMethodMethod(const v8::FunctionCallbackI
switch (std::min(1, info.Length())) {
case 0:
if (true) {
- measureAsSameValueOverloadedMethod1Method(info);
+ measureAsSameValueOverloadedMethod1Method(info, -1);
return;
}
break;
case 1:
if (true) {
- measureAsSameValueOverloadedMethod2Method(info);
+ measureAsSameValueOverloadedMethod2Method(info, -1);
return;
}
break;
@@ -8903,13 +8918,13 @@ static void measureAsSameValueOverloadedMethodMethodCallback(const v8::FunctionC
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void deprecateAsMeasureAsSameValueOverloadedMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void deprecateAsMeasureAsSameValueOverloadedMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
impl->deprecateAsMeasureAsSameValueOverloadedMethod();
}
-static void deprecateAsMeasureAsSameValueOverloadedMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void deprecateAsMeasureAsSameValueOverloadedMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "deprecateAsMeasureAsSameValueOverloadedMethod", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -8928,14 +8943,14 @@ static void deprecateAsMeasureAsSameValueOverloadedMethodMethod(const v8::Functi
case 0:
if (true) {
UseCounter::countDeprecation(callingExecutionContext(info.GetIsolate()), UseCounter::TestFeatureA);
- deprecateAsMeasureAsSameValueOverloadedMethod1Method(info);
+ deprecateAsMeasureAsSameValueOverloadedMethod1Method(info, -1);
return;
}
break;
case 1:
if (true) {
UseCounter::countDeprecation(callingExecutionContext(info.GetIsolate()), UseCounter::TestFeatureB);
- deprecateAsMeasureAsSameValueOverloadedMethod2Method(info);
+ deprecateAsMeasureAsSameValueOverloadedMethod2Method(info, -1);
return;
}
break;
@@ -8955,13 +8970,13 @@ static void deprecateAsMeasureAsSameValueOverloadedMethodMethodCallback(const v8
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void deprecateAsSameValueMeasureAsOverloadedMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void deprecateAsSameValueMeasureAsOverloadedMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
impl->deprecateAsSameValueMeasureAsOverloadedMethod();
}
-static void deprecateAsSameValueMeasureAsOverloadedMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void deprecateAsSameValueMeasureAsOverloadedMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "deprecateAsSameValueMeasureAsOverloadedMethod", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -8980,14 +8995,14 @@ static void deprecateAsSameValueMeasureAsOverloadedMethodMethod(const v8::Functi
case 0:
if (true) {
UseCounter::count(callingExecutionContext(info.GetIsolate()), UseCounter::TestFeatureA);
- deprecateAsSameValueMeasureAsOverloadedMethod1Method(info);
+ deprecateAsSameValueMeasureAsOverloadedMethod1Method(info, -1);
return;
}
break;
case 1:
if (true) {
UseCounter::count(callingExecutionContext(info.GetIsolate()), UseCounter::TestFeatureB);
- deprecateAsSameValueMeasureAsOverloadedMethod2Method(info);
+ deprecateAsSameValueMeasureAsOverloadedMethod2Method(info, -1);
return;
}
break;
@@ -9007,13 +9022,13 @@ static void deprecateAsSameValueMeasureAsOverloadedMethodMethodCallback(const v8
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void deprecateAsSameValueMeasureAsSameValueOverloadedMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void deprecateAsSameValueMeasureAsSameValueOverloadedMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
impl->deprecateAsSameValueMeasureAsSameValueOverloadedMethod();
}
-static void deprecateAsSameValueMeasureAsSameValueOverloadedMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void deprecateAsSameValueMeasureAsSameValueOverloadedMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "deprecateAsSameValueMeasureAsSameValueOverloadedMethod", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -9032,13 +9047,13 @@ static void deprecateAsSameValueMeasureAsSameValueOverloadedMethodMethod(const v
switch (std::min(1, info.Length())) {
case 0:
if (true) {
- deprecateAsSameValueMeasureAsSameValueOverloadedMethod1Method(info);
+ deprecateAsSameValueMeasureAsSameValueOverloadedMethod1Method(info, -1);
return;
}
break;
case 1:
if (true) {
- deprecateAsSameValueMeasureAsSameValueOverloadedMethod2Method(info);
+ deprecateAsSameValueMeasureAsSameValueOverloadedMethod2Method(info, -1);
return;
}
break;
@@ -9441,7 +9456,7 @@ static void perWorldBindingsRuntimeEnabledVoidMethodMethodCallbackForMainWorld(c
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void runtimeEnabledOverloadedVoidMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void runtimeEnabledOverloadedVoidMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
V8StringResource<> stringArg;
@@ -9451,7 +9466,7 @@ static void runtimeEnabledOverloadedVoidMethod1Method(const v8::FunctionCallback
impl->runtimeEnabledOverloadedVoidMethod(stringArg);
}
-static void runtimeEnabledOverloadedVoidMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void runtimeEnabledOverloadedVoidMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "runtimeEnabledOverloadedVoidMethod", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -9468,15 +9483,15 @@ static void runtimeEnabledOverloadedVoidMethodMethod(const v8::FunctionCallbackI
switch (std::min(1, info.Length())) {
case 1:
if (info[0]->IsNumber()) {
- runtimeEnabledOverloadedVoidMethod2Method(info);
+ runtimeEnabledOverloadedVoidMethod2Method(info, 0);
return;
}
if (true) {
- runtimeEnabledOverloadedVoidMethod1Method(info);
+ runtimeEnabledOverloadedVoidMethod1Method(info, -1);
return;
}
if (true) {
- runtimeEnabledOverloadedVoidMethod2Method(info);
+ runtimeEnabledOverloadedVoidMethod2Method(info, -1);
return;
}
break;
@@ -9496,7 +9511,7 @@ static void runtimeEnabledOverloadedVoidMethodMethodCallback(const v8::FunctionC
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
-static void partiallyRuntimeEnabledOverloadedVoidMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void partiallyRuntimeEnabledOverloadedVoidMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
V8StringResource<> stringArg;
@@ -9506,17 +9521,20 @@ static void partiallyRuntimeEnabledOverloadedVoidMethod1Method(const v8::Functio
impl->partiallyRuntimeEnabledOverloadedVoidMethod(stringArg);
}
-static void partiallyRuntimeEnabledOverloadedVoidMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void partiallyRuntimeEnabledOverloadedVoidMethod2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
TestObject* impl = V8TestObject::toImpl(info.Holder());
TestInterfaceImplementation* testInterface;
{
- testInterface = V8TestInterface::toImplWithTypeCheck(info.GetIsolate(), info[0]);
+ if (typeCheckedArgumentIndex == 0)
+ testInterface = V8TestInterface::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
+ else
+ testInterface = V8TestInterface::toImplWithTypeCheck(info.GetIsolate(), info[0]);
}
impl->partiallyRuntimeEnabledOverloadedVoidMethod(testInterface);
}
-static void partiallyRuntimeEnabledOverloadedVoidMethod3Method(const v8::FunctionCallbackInfo<v8::Value>& info)
+static void partiallyRuntimeEnabledOverloadedVoidMethod3Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "partiallyRuntimeEnabledOverloadedVoidMethod", "TestObject", info.Holder(), info.GetIsolate());
TestObject* impl = V8TestObject::toImpl(info.Holder());
@@ -9534,22 +9552,22 @@ static void partiallyRuntimeEnabledOverloadedVoidMethodMethod(const v8::Function
case 1:
if (RuntimeEnabledFeatures::featureName2Enabled()) {
if (V8TestInterface::hasInstance(info[0], info.GetIsolate())) {
- partiallyRuntimeEnabledOverloadedVoidMethod2Method(info);
+ partiallyRuntimeEnabledOverloadedVoidMethod2Method(info, 0);
return;
}
}
if (info[0]->IsNumber()) {
- partiallyRuntimeEnabledOverloadedVoidMethod3Method(info);
+ partiallyRuntimeEnabledOverloadedVoidMethod3Method(info, 0);
return;
}
if (RuntimeEnabledFeatures::featureName1Enabled()) {
if (true) {
- partiallyRuntimeEnabledOverloadedVoidMethod1Method(info);
+ partiallyRuntimeEnabledOverloadedVoidMethod1Method(info, -1);
return;
}
}
if (true) {
- partiallyRuntimeEnabledOverloadedVoidMethod3Method(info);
+ partiallyRuntimeEnabledOverloadedVoidMethod3Method(info, -1);
return;
}
break;
@@ -9660,7 +9678,7 @@ static void typeCheckingInterfaceVoidMethodTestInterfaceEmptyArgMethod(const v8:
V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute("typeCheckingInterfaceVoidMethodTestInterfaceEmptyArg", "TestObject", "parameter 1 is not of type 'TestInterfaceEmpty'."), info.GetIsolate());
return;
}
- testInterfaceEmptyArg = V8TestInterfaceEmpty::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
+ testInterfaceEmptyArg = V8TestInterfaceEmpty::toImplWithTypeCheck(info.GetIsolate(), info[0]);
}
impl->typeCheckingInterfaceVoidMethodTestInterfaceEmptyArg(testInterfaceEmptyArg);
}
@@ -9711,7 +9729,7 @@ static void useToImpl4ArgumentsCheckingIfPossibleWithOptionalArgMethod(const v8:
V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute("useToImpl4ArgumentsCheckingIfPossibleWithOptionalArg", "TestObject", "parameter 1 is not of type 'Node'."), info.GetIsolate());
return;
}
- node1 = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
+ node1 = V8Node::toImplWithTypeCheck(info.GetIsolate(), info[0]);
if (UNLIKELY(info.Length() <= 1)) {
impl->useToImpl4ArgumentsCheckingIfPossibleWithOptionalArg(node1);
return;
@@ -9720,7 +9738,7 @@ static void useToImpl4ArgumentsCheckingIfPossibleWithOptionalArgMethod(const v8:
V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute("useToImpl4ArgumentsCheckingIfPossibleWithOptionalArg", "TestObject", "parameter 2 is not of type 'Node'."), info.GetIsolate());
return;
}
- node2 = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[1]));
+ node2 = V8Node::toImplWithTypeCheck(info.GetIsolate(), info[1]);
}
impl->useToImpl4ArgumentsCheckingIfPossibleWithOptionalArg(node1, node2);
}
@@ -9746,7 +9764,7 @@ static void useToImpl4ArgumentsCheckingIfPossibleWithNullableArgMethod(const v8:
V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute("useToImpl4ArgumentsCheckingIfPossibleWithNullableArg", "TestObject", "parameter 1 is not of type 'Node'."), info.GetIsolate());
return;
}
- node1 = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
+ node1 = V8Node::toImplWithTypeCheck(info.GetIsolate(), info[0]);
if (info.Length() > 1 && !isUndefinedOrNull(info[1]) && !V8Node::hasInstance(info[1], info.GetIsolate())) {
V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute("useToImpl4ArgumentsCheckingIfPossibleWithNullableArg", "TestObject", "parameter 2 is not of type 'Node'."), info.GetIsolate());
return;
@@ -9777,7 +9795,7 @@ static void useToImpl4ArgumentsCheckingIfPossibleWithUndefinedArgMethod(const v8
V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute("useToImpl4ArgumentsCheckingIfPossibleWithUndefinedArg", "TestObject", "parameter 1 is not of type 'Node'."), info.GetIsolate());
return;
}
- node1 = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
+ node1 = V8Node::toImplWithTypeCheck(info.GetIsolate(), info[0]);
if (info.Length() > 1 && !V8Node::hasInstance(info[1], info.GetIsolate())) {
V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute("useToImpl4ArgumentsCheckingIfPossibleWithUndefinedArg", "TestObject", "parameter 2 is not of type 'Node'."), info.GetIsolate());
return;
@@ -9794,6 +9812,449 @@ static void useToImpl4ArgumentsCheckingIfPossibleWithUndefinedArgMethodCallback(
TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
}
+static void typeCheckingMaybeRedundantForOverloadingMethodsA1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
+{
+ ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckingMaybeRedundantForOverloadingMethodsA", "TestObject", info.Holder(), info.GetIsolate());
+ TestObject* impl = V8TestObject::toImpl(info.Holder());
+ Node* a;
+ int b;
+ {
+ if (info.Length() > 0 && !V8Node::hasInstance(info[0], info.GetIsolate())) {
+ exceptionState.throwTypeError("parameter 1 is not of type 'Node'.");
+ exceptionState.throwIfNeeded();
+ return;
+ }
+ if (typeCheckedArgumentIndex == 0)
+ a = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
+ else
+ a = V8Node::toImplWithTypeCheck(info.GetIsolate(), info[0]);
+ TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(b, toInt32(info[1], exceptionState), exceptionState);
+ }
+ impl->typeCheckingMaybeRedundantForOverloadingMethodsA(a, b);
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsA2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
+{
+ ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckingMaybeRedundantForOverloadingMethodsA", "TestObject", info.Holder(), info.GetIsolate());
+ TestObject* impl = V8TestObject::toImpl(info.Holder());
+ int a;
+ int b;
+ {
+ TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(a, toInt32(info[0], exceptionState), exceptionState);
+ TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(b, toInt32(info[1], exceptionState), exceptionState);
+ }
+ impl->typeCheckingMaybeRedundantForOverloadingMethodsA(a, b);
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsAMethod(const v8::FunctionCallbackInfo<v8::Value>& info)
+{
+ ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckingMaybeRedundantForOverloadingMethodsA", "TestObject", info.Holder(), info.GetIsolate());
+ switch (std::min(2, info.Length())) {
+ case 2:
+ if (V8Node::hasInstance(info[0], info.GetIsolate())) {
+ typeCheckingMaybeRedundantForOverloadingMethodsA1Method(info, 0);
+ return;
+ }
+ if (true) {
+ typeCheckingMaybeRedundantForOverloadingMethodsA2Method(info, -1);
+ return;
+ }
+ break;
+ default:
+ exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(2, info.Length()));
+ exceptionState.throwIfNeeded();
+ return;
+ }
+ exceptionState.throwTypeError("No function was found that matched the signature provided.");
+ exceptionState.throwIfNeeded();
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsAMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info)
+{
+ TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod");
+ TestObjectV8Internal::typeCheckingMaybeRedundantForOverloadingMethodsAMethod(info);
+ TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsB1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
+{
+ TestObject* impl = V8TestObject::toImpl(info.Holder());
+ Node* a;
+ {
+ if (info.Length() > 0 && !V8Node::hasInstance(info[0], info.GetIsolate())) {
+ V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute("typeCheckingMaybeRedundantForOverloadingMethodsB", "TestObject", "parameter 1 is not of type 'Node'."), info.GetIsolate());
+ return;
+ }
+ a = V8Node::toImplWithTypeCheck(info.GetIsolate(), info[0]);
+ }
+ impl->typeCheckingMaybeRedundantForOverloadingMethodsB(a);
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsB2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
+{
+ ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckingMaybeRedundantForOverloadingMethodsB", "TestObject", info.Holder(), info.GetIsolate());
+ TestObject* impl = V8TestObject::toImpl(info.Holder());
+ int a;
+ int b;
+ {
+ TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(a, toInt32(info[0], exceptionState), exceptionState);
+ TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(b, toInt32(info[1], exceptionState), exceptionState);
+ }
+ impl->typeCheckingMaybeRedundantForOverloadingMethodsB(a, b);
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsBMethod(const v8::FunctionCallbackInfo<v8::Value>& info)
+{
+ ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckingMaybeRedundantForOverloadingMethodsB", "TestObject", info.Holder(), info.GetIsolate());
+ switch (std::min(2, info.Length())) {
+ case 1:
+ if (true) {
+ typeCheckingMaybeRedundantForOverloadingMethodsB1Method(info, -1);
+ return;
+ }
+ break;
+ case 2:
+ if (true) {
+ typeCheckingMaybeRedundantForOverloadingMethodsB2Method(info, -1);
+ return;
+ }
+ break;
+ default:
+ exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, info.Length()));
+ exceptionState.throwIfNeeded();
+ return;
+ }
+ exceptionState.throwTypeError("No function was found that matched the signature provided.");
+ exceptionState.throwIfNeeded();
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsBMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info)
+{
+ TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod");
+ TestObjectV8Internal::typeCheckingMaybeRedundantForOverloadingMethodsBMethod(info);
+ TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsC1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
+{
+ TestObject* impl = V8TestObject::toImpl(info.Holder());
+ Node* a;
+ {
+ if (info.Length() > 0 && !V8Node::hasInstance(info[0], info.GetIsolate())) {
+ V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute("typeCheckingMaybeRedundantForOverloadingMethodsC", "TestObject", "parameter 1 is not of type 'Node'."), info.GetIsolate());
+ return;
+ }
+ if (typeCheckedArgumentIndex == 0)
+ a = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
+ else
+ a = V8Node::toImplWithTypeCheck(info.GetIsolate(), info[0]);
+ }
+ impl->typeCheckingMaybeRedundantForOverloadingMethodsC(a);
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsC2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
+{
+ ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckingMaybeRedundantForOverloadingMethodsC", "TestObject", info.Holder(), info.GetIsolate());
+ TestObject* impl = V8TestObject::toImpl(info.Holder());
+ int a;
+ int b;
+ {
+ TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(a, toInt32(info[0], exceptionState), exceptionState);
+ if (UNLIKELY(info.Length() <= 1)) {
+ impl->typeCheckingMaybeRedundantForOverloadingMethodsC(a);
+ return;
+ }
+ TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(b, toInt32(info[1], exceptionState), exceptionState);
+ }
+ impl->typeCheckingMaybeRedundantForOverloadingMethodsC(a, b);
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsCMethod(const v8::FunctionCallbackInfo<v8::Value>& info)
+{
+ ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckingMaybeRedundantForOverloadingMethodsC", "TestObject", info.Holder(), info.GetIsolate());
+ switch (std::min(2, info.Length())) {
+ case 1:
+ if (V8Node::hasInstance(info[0], info.GetIsolate())) {
+ typeCheckingMaybeRedundantForOverloadingMethodsC1Method(info, 0);
+ return;
+ }
+ if (true) {
+ typeCheckingMaybeRedundantForOverloadingMethodsC2Method(info, -1);
+ return;
+ }
+ break;
+ case 2:
+ if (true) {
+ typeCheckingMaybeRedundantForOverloadingMethodsC2Method(info, -1);
+ return;
+ }
+ break;
+ default:
+ exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, info.Length()));
+ exceptionState.throwIfNeeded();
+ return;
+ }
+ exceptionState.throwTypeError("No function was found that matched the signature provided.");
+ exceptionState.throwIfNeeded();
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsCMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info)
+{
+ TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod");
+ TestObjectV8Internal::typeCheckingMaybeRedundantForOverloadingMethodsCMethod(info);
+ TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsD1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
+{
+ TestObject* impl = V8TestObject::toImpl(info.Holder());
+ Node* a;
+ Node* b;
+ {
+ if (info.Length() > 0 && !V8Node::hasInstance(info[0], info.GetIsolate())) {
+ V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute("typeCheckingMaybeRedundantForOverloadingMethodsD", "TestObject", "parameter 1 is not of type 'Node'."), info.GetIsolate());
+ return;
+ }
+ a = V8Node::toImplWithTypeCheck(info.GetIsolate(), info[0]);
+ if (info.Length() > 1 && !V8Node::hasInstance(info[1], info.GetIsolate())) {
+ V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute("typeCheckingMaybeRedundantForOverloadingMethodsD", "TestObject", "parameter 2 is not of type 'Node'."), info.GetIsolate());
+ return;
+ }
+ if (typeCheckedArgumentIndex == 1)
+ b = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[1]));
+ else
+ b = V8Node::toImplWithTypeCheck(info.GetIsolate(), info[1]);
+ }
+ impl->typeCheckingMaybeRedundantForOverloadingMethodsD(a, b);
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsD2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
+{
+ ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckingMaybeRedundantForOverloadingMethodsD", "TestObject", info.Holder(), info.GetIsolate());
+ TestObject* impl = V8TestObject::toImpl(info.Holder());
+ Node* a;
+ int b;
+ {
+ if (info.Length() > 0 && !V8Node::hasInstance(info[0], info.GetIsolate())) {
+ exceptionState.throwTypeError("parameter 1 is not of type 'Node'.");
+ exceptionState.throwIfNeeded();
+ return;
+ }
+ a = V8Node::toImplWithTypeCheck(info.GetIsolate(), info[0]);
+ TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(b, toInt32(info[1], exceptionState), exceptionState);
+ }
+ impl->typeCheckingMaybeRedundantForOverloadingMethodsD(a, b);
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsDMethod(const v8::FunctionCallbackInfo<v8::Value>& info)
+{
+ ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckingMaybeRedundantForOverloadingMethodsD", "TestObject", info.Holder(), info.GetIsolate());
+ switch (std::min(2, info.Length())) {
+ case 2:
+ if (V8Node::hasInstance(info[1], info.GetIsolate())) {
+ typeCheckingMaybeRedundantForOverloadingMethodsD1Method(info, 1);
+ return;
+ }
+ if (true) {
+ typeCheckingMaybeRedundantForOverloadingMethodsD2Method(info, -1);
+ return;
+ }
+ break;
+ default:
+ exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(2, info.Length()));
+ exceptionState.throwIfNeeded();
+ return;
+ }
+ exceptionState.throwTypeError("No function was found that matched the signature provided.");
+ exceptionState.throwIfNeeded();
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsDMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info)
+{
+ TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod");
+ TestObjectV8Internal::typeCheckingMaybeRedundantForOverloadingMethodsDMethod(info);
+ TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsE1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
+{
+ TestObject* impl = V8TestObject::toImpl(info.Holder());
+ Node* a;
+ Node* b;
+ {
+ if (info.Length() > 0 && !V8Node::hasInstance(info[0], info.GetIsolate())) {
+ V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute("typeCheckingMaybeRedundantForOverloadingMethodsE", "TestObject", "parameter 1 is not of type 'Node'."), info.GetIsolate());
+ return;
+ }
+ a = V8Node::toImplWithTypeCheck(info.GetIsolate(), info[0]);
+ if (info.Length() > 1 && !V8Node::hasInstance(info[1], info.GetIsolate())) {
+ V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute("typeCheckingMaybeRedundantForOverloadingMethodsE", "TestObject", "parameter 2 is not of type 'Node'."), info.GetIsolate());
+ return;
+ }
+ if (typeCheckedArgumentIndex == 1)
+ b = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[1]));
+ else
+ b = V8Node::toImplWithTypeCheck(info.GetIsolate(), info[1]);
+ }
+ impl->typeCheckingMaybeRedundantForOverloadingMethodsE(a, b);
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsE2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
+{
+ ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckingMaybeRedundantForOverloadingMethodsE", "TestObject", info.Holder(), info.GetIsolate());
+ TestObject* impl = V8TestObject::toImpl(info.Holder());
+ Node* a;
+ int b;
+ {
+ if (info.Length() > 0 && !V8Node::hasInstance(info[0], info.GetIsolate())) {
+ exceptionState.throwTypeError("parameter 1 is not of type 'Node'.");
+ exceptionState.throwIfNeeded();
+ return;
+ }
+ a = V8Node::toImplWithTypeCheck(info.GetIsolate(), info[0]);
+ if (UNLIKELY(info.Length() <= 1)) {
+ impl->typeCheckingMaybeRedundantForOverloadingMethodsE(a);
+ return;
+ }
+ TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(b, toInt32(info[1], exceptionState), exceptionState);
+ }
+ impl->typeCheckingMaybeRedundantForOverloadingMethodsE(a, b);
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsEMethod(const v8::FunctionCallbackInfo<v8::Value>& info)
+{
+ ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckingMaybeRedundantForOverloadingMethodsE", "TestObject", info.Holder(), info.GetIsolate());
+ switch (std::min(2, info.Length())) {
+ case 1:
+ if (true) {
+ typeCheckingMaybeRedundantForOverloadingMethodsE2Method(info, -1);
+ return;
+ }
+ break;
+ case 2:
+ if (info[1]->IsUndefined()) {
+ typeCheckingMaybeRedundantForOverloadingMethodsE2Method(info, -1);
+ return;
+ }
+ if (V8Node::hasInstance(info[1], info.GetIsolate())) {
+ typeCheckingMaybeRedundantForOverloadingMethodsE1Method(info, 1);
+ return;
+ }
+ if (true) {
+ typeCheckingMaybeRedundantForOverloadingMethodsE2Method(info, -1);
+ return;
+ }
+ break;
+ default:
+ exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, info.Length()));
+ exceptionState.throwIfNeeded();
+ return;
+ }
+ exceptionState.throwTypeError("No function was found that matched the signature provided.");
+ exceptionState.throwIfNeeded();
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsEMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info)
+{
+ TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod");
+ TestObjectV8Internal::typeCheckingMaybeRedundantForOverloadingMethodsEMethod(info);
+ TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsF1Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
+{
+ TestObject* impl = V8TestObject::toImpl(info.Holder());
+ Node* a;
+ {
+ if (UNLIKELY(info.Length() <= 0)) {
+ impl->typeCheckingMaybeRedundantForOverloadingMethodsF();
+ return;
+ }
+ if (info.Length() > 0 && !V8Node::hasInstance(info[0], info.GetIsolate())) {
+ V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute("typeCheckingMaybeRedundantForOverloadingMethodsF", "TestObject", "parameter 1 is not of type 'Node'."), info.GetIsolate());
+ return;
+ }
+ if (typeCheckedArgumentIndex == 0)
+ a = V8Node::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
+ else
+ a = V8Node::toImplWithTypeCheck(info.GetIsolate(), info[0]);
+ }
+ impl->typeCheckingMaybeRedundantForOverloadingMethodsF(a);
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsF2Method(const v8::FunctionCallbackInfo<v8::Value>& info, int typeCheckedArgumentIndex)
+{
+ TestObject* impl = V8TestObject::toImpl(info.Holder());
+ Document* a;
+ Node* b;
+ {
+ if (info.Length() > 0 && !V8Document::hasInstance(info[0], info.GetIsolate())) {
+ V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute("typeCheckingMaybeRedundantForOverloadingMethodsF", "TestObject", "parameter 1 is not of type 'Document'."), info.GetIsolate());
+ return;
+ }
+ if (typeCheckedArgumentIndex == 0)
+ a = V8Document::toImpl(v8::Handle<v8::Object>::Cast(info[0]));
+ else
+ a = V8Document::toImplWithTypeCheck(info.GetIsolate(), info[0]);
+ if (UNLIKELY(info.Length() <= 1)) {
+ impl->typeCheckingMaybeRedundantForOverloadingMethodsF(a);
+ return;
+ }
+ if (info.Length() > 1 && !V8Node::hasInstance(info[1], info.GetIsolate())) {
+ V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute("typeCheckingMaybeRedundantForOverloadingMethodsF", "TestObject", "parameter 2 is not of type 'Node'."), info.GetIsolate());
+ return;
+ }
+ b = V8Node::toImplWithTypeCheck(info.GetIsolate(), info[1]);
+ }
+ impl->typeCheckingMaybeRedundantForOverloadingMethodsF(a, b);
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsFMethod(const v8::FunctionCallbackInfo<v8::Value>& info)
+{
+ ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckingMaybeRedundantForOverloadingMethodsF", "TestObject", info.Holder(), info.GetIsolate());
+ switch (std::min(2, info.Length())) {
+ case 0:
+ if (true) {
+ typeCheckingMaybeRedundantForOverloadingMethodsF1Method(info, -1);
+ return;
+ }
+ break;
+ case 1:
+ if (info[0]->IsUndefined()) {
+ typeCheckingMaybeRedundantForOverloadingMethodsF1Method(info, -1);
+ return;
+ }
+ if (V8Node::hasInstance(info[0], info.GetIsolate())) {
+ typeCheckingMaybeRedundantForOverloadingMethodsF1Method(info, 0);
+ return;
+ }
+ if (V8Document::hasInstance(info[0], info.GetIsolate())) {
+ typeCheckingMaybeRedundantForOverloadingMethodsF2Method(info, 0);
+ return;
+ }
+ break;
+ case 2:
+ if (true) {
+ typeCheckingMaybeRedundantForOverloadingMethodsF2Method(info, -1);
+ return;
+ }
+ break;
+ default:
+ exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(0, info.Length()));
+ exceptionState.throwIfNeeded();
+ return;
+ }
+ exceptionState.throwTypeError("No function was found that matched the signature provided.");
+ exceptionState.throwIfNeeded();
+}
+
+static void typeCheckingMaybeRedundantForOverloadingMethodsFMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info)
+{
+ TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod");
+ TestObjectV8Internal::typeCheckingMaybeRedundantForOverloadingMethodsFMethod(info);
+ TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
+}
+
static void typeCheckingUnrestrictedVoidMethodFloatArgDoubleArgMethod(const v8::FunctionCallbackInfo<v8::Value>& info)
{
ExceptionState exceptionState(ExceptionState::ExecutionContext, "typeCheckingUnrestrictedVoidMethodFloatArgDoubleArg", "TestObject", info.Holder(), info.GetIsolate());
@@ -10472,6 +10933,12 @@ static const V8DOMConfiguration::MethodConfiguration V8TestObjectMethods[] = {
{"useToImpl4ArgumentsCheckingIfPossibleWithOptionalArg", TestObjectV8Internal::useToImpl4ArgumentsCheckingIfPossibleWithOptionalArgMethodCallback, 0, 1, V8DOMConfiguration::ExposedToAllScripts},
{"useToImpl4ArgumentsCheckingIfPossibleWithNullableArg", TestObjectV8Internal::useToImpl4ArgumentsCheckingIfPossibleWithNullableArgMethodCallback, 0, 2, V8DOMConfiguration::ExposedToAllScripts},
{"useToImpl4ArgumentsCheckingIfPossibleWithUndefinedArg", TestObjectV8Internal::useToImpl4ArgumentsCheckingIfPossibleWithUndefinedArgMethodCallback, 0, 1, V8DOMConfiguration::ExposedToAllScripts},
+ {"typeCheckingMaybeRedundantForOverloadingMethodsA", TestObjectV8Internal::typeCheckingMaybeRedundantForOverloadingMethodsAMethodCallback, 0, 2, V8DOMConfiguration::ExposedToAllScripts},
+ {"typeCheckingMaybeRedundantForOverloadingMethodsB", TestObjectV8Internal::typeCheckingMaybeRedundantForOverloadingMethodsBMethodCallback, 0, 1, V8DOMConfiguration::ExposedToAllScripts},
+ {"typeCheckingMaybeRedundantForOverloadingMethodsC", TestObjectV8Internal::typeCheckingMaybeRedundantForOverloadingMethodsCMethodCallback, 0, 1, V8DOMConfiguration::ExposedToAllScripts},
+ {"typeCheckingMaybeRedundantForOverloadingMethodsD", TestObjectV8Internal::typeCheckingMaybeRedundantForOverloadingMethodsDMethodCallback, 0, 2, V8DOMConfiguration::ExposedToAllScripts},
+ {"typeCheckingMaybeRedundantForOverloadingMethodsE", TestObjectV8Internal::typeCheckingMaybeRedundantForOverloadingMethodsEMethodCallback, 0, 1, V8DOMConfiguration::ExposedToAllScripts},
+ {"typeCheckingMaybeRedundantForOverloadingMethodsF", TestObjectV8Internal::typeCheckingMaybeRedundantForOverloadingMethodsFMethodCallback, 0, 0, V8DOMConfiguration::ExposedToAllScripts},
{"typeCheckingUnrestrictedVoidMethodFloatArgDoubleArg", TestObjectV8Internal::typeCheckingUnrestrictedVoidMethodFloatArgDoubleArgMethodCallback, 0, 2, V8DOMConfiguration::ExposedToAllScripts},
{"voidMethodTestInterfaceGarbageCollectedSequenceArg", TestObjectV8Internal::voidMethodTestInterfaceGarbageCollectedSequenceArgMethodCallback, 0, 1, V8DOMConfiguration::ExposedToAllScripts},
{"voidMethodTestInterfaceGarbageCollectedArrayArg", TestObjectV8Internal::voidMethodTestInterfaceGarbageCollectedArrayArgMethodCallback, 0, 1, V8DOMConfiguration::ExposedToAllScripts},

Powered by Google App Engine
This is Rietveld 408576698