blob: ca0577ea4caabce42bb4ec1aad8062b59eaaa8e4 [file] [log] [blame]
jochen4879fd2c2014-09-16 15:04:291// Copyright 2014 The Chromium Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#include "gin/debug_impl.h"
6
7namespace gin {
8
9namespace {
jochen4879fd2c2014-09-16 15:04:2910v8::JitCodeEventHandler g_jit_code_event_handler = NULL;
11} // namespace
12
13// static
jochen4879fd2c2014-09-16 15:04:2914void Debug::SetJitCodeEventHandler(v8::JitCodeEventHandler event_handler) {
15 g_jit_code_event_handler = event_handler;
16}
17
jochen284435c2014-10-02 13:08:2318#if defined(OS_WIN)
19// static
Paolo Severinifb4ab3b2019-04-16 00:17:4920void Debug::SetUnhandledExceptionCallback(
21 v8::UnhandledExceptionCallback callback) {
22 v8::V8::SetUnhandledExceptionCallback(callback);
jochen284435c2014-10-02 13:08:2323}
24#endif
25
jochen4879fd2c2014-09-16 15:04:2926// static
jochen4879fd2c2014-09-16 15:04:2927v8::JitCodeEventHandler DebugImpl::GetJitCodeEventHandler() {
28 return g_jit_code_event_handler;
29}
30
jochen4879fd2c2014-09-16 15:04:2931} // namespace gin