Index: test/cctest/compiler/test-run-inlining.cc |
diff --git a/test/cctest/compiler/test-run-inlining.cc b/test/cctest/compiler/test-run-inlining.cc |
index a6d76e4d578b9ebe4624324cf6ba027f36c40253..61f3b62e89e49856f8ae4914178c4e764e2553d1 100644 |
--- a/test/cctest/compiler/test-run-inlining.cc |
+++ b/test/cctest/compiler/test-run-inlining.cc |
@@ -526,4 +526,32 @@ TEST(InlineNestedBuiltin) { |
T.CheckCall(T.true_value()); |
} |
+ |
+TEST(StrongModeArity) { |
+ FLAG_turbo_deoptimization = true; |
+ FLAG_strong_mode = true; |
+ FunctionTester T( |
+ "(function () {" |
+ " function foo(x, y) { 'use strong'; return x; }" |
+ " function bar(x, y) { return foo(x); }" |
+ " return bar;" |
+ "})();", |
+ kInlineFlags); |
+ T.CheckThrows(T.undefined(), T.undefined()); |
+} |
+ |
+ |
+TEST(StrongModeArityOuter) { |
+ FLAG_turbo_deoptimization = true; |
+ FLAG_strong_mode = true; |
+ FunctionTester T( |
+ "(function () {" |
+ " 'use strong';" |
+ " function foo(x, y) { return x; }" |
+ " function bar(x, y) { return foo(x); }" |
+ " return bar;" |
+ "})();", |
+ kInlineFlags); |
+ T.CheckThrows(T.undefined(), T.undefined()); |
+} |
#endif // V8_TURBOFAN_TARGET |