2014-10-01 14:03:02 +00:00
|
|
|
// Copyright 2014 the V8 project authors. All rights reserved.
|
|
|
|
// Use of this source code is governed by a BSD-style license that can be
|
|
|
|
// found in the LICENSE file.
|
|
|
|
|
2016-09-01 12:01:33 +00:00
|
|
|
#include "src/isolate.h"
|
2014-10-01 14:03:02 +00:00
|
|
|
#include "test/cctest/compiler/function-tester.h"
|
|
|
|
|
2015-10-30 09:16:26 +00:00
|
|
|
namespace v8 {
|
|
|
|
namespace internal {
|
|
|
|
namespace compiler {
|
2014-10-01 14:03:02 +00:00
|
|
|
|
|
|
|
TEST(TerminateAtMethodEntry) {
|
2017-06-12 14:58:54 +00:00
|
|
|
FLAG_ignition = true;
|
2014-10-01 14:03:02 +00:00
|
|
|
FunctionTester T("(function(a,b) { return 23; })");
|
|
|
|
|
|
|
|
T.CheckCall(T.Val(23));
|
|
|
|
T.isolate->stack_guard()->RequestTerminateExecution();
|
|
|
|
T.CheckThrows(T.undefined(), T.undefined());
|
|
|
|
}
|
2015-10-30 09:16:26 +00:00
|
|
|
|
|
|
|
} // namespace compiler
|
|
|
|
} // namespace internal
|
|
|
|
} // namespace v8
|