OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project 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 #ifndef V8_DEBUG_H_ | 5 #ifndef V8_DEBUG_H_ |
6 #define V8_DEBUG_H_ | 6 #define V8_DEBUG_H_ |
7 | 7 |
8 #include "src/allocation.h" | 8 #include "src/allocation.h" |
9 #include "src/arguments.h" | 9 #include "src/arguments.h" |
10 #include "src/assembler.h" | 10 #include "src/assembler.h" |
(...skipping 354 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
365 class Debug { | 365 class Debug { |
366 public: | 366 public: |
367 enum AfterCompileFlags { | 367 enum AfterCompileFlags { |
368 NO_AFTER_COMPILE_FLAGS, | 368 NO_AFTER_COMPILE_FLAGS, |
369 SEND_WHEN_DEBUGGING | 369 SEND_WHEN_DEBUGGING |
370 }; | 370 }; |
371 | 371 |
372 // Debug event triggers. | 372 // Debug event triggers. |
373 void OnDebugBreak(Handle<Object> break_points_hit, bool auto_continue); | 373 void OnDebugBreak(Handle<Object> break_points_hit, bool auto_continue); |
374 void OnException(Handle<Object> exception, bool uncaught); | 374 void OnException(Handle<Object> exception, bool uncaught); |
| 375 void OnCompileError(Handle<Script> script); |
375 void OnBeforeCompile(Handle<Script> script); | 376 void OnBeforeCompile(Handle<Script> script); |
376 void OnAfterCompile(Handle<Script> script, | 377 void OnAfterCompile(Handle<Script> script, |
377 AfterCompileFlags after_compile_flags); | 378 AfterCompileFlags after_compile_flags); |
378 void OnScriptCollected(int id); | 379 void OnScriptCollected(int id); |
379 | 380 |
380 // API facing. | 381 // API facing. |
381 void SetEventListener(Handle<Object> callback, Handle<Object> data); | 382 void SetEventListener(Handle<Object> callback, Handle<Object> data); |
382 void SetMessageHandler(v8::Debug::MessageHandler handler); | 383 void SetMessageHandler(v8::Debug::MessageHandler handler); |
383 void EnqueueCommandMessage(Vector<const uint16_t> command, | 384 void EnqueueCommandMessage(Vector<const uint16_t> command, |
384 v8::Debug::ClientData* client_data = NULL); | 385 v8::Debug::ClientData* client_data = NULL); |
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
541 int argc, | 542 int argc, |
542 Handle<Object> argv[]); | 543 Handle<Object> argv[]); |
543 MUST_USE_RESULT MaybeHandle<Object> MakeExecutionState(); | 544 MUST_USE_RESULT MaybeHandle<Object> MakeExecutionState(); |
544 MUST_USE_RESULT MaybeHandle<Object> MakeBreakEvent( | 545 MUST_USE_RESULT MaybeHandle<Object> MakeBreakEvent( |
545 Handle<Object> break_points_hit); | 546 Handle<Object> break_points_hit); |
546 MUST_USE_RESULT MaybeHandle<Object> MakeExceptionEvent( | 547 MUST_USE_RESULT MaybeHandle<Object> MakeExceptionEvent( |
547 Handle<Object> exception, | 548 Handle<Object> exception, |
548 bool uncaught, | 549 bool uncaught, |
549 Handle<Object> promise); | 550 Handle<Object> promise); |
550 MUST_USE_RESULT MaybeHandle<Object> MakeCompileEvent( | 551 MUST_USE_RESULT MaybeHandle<Object> MakeCompileEvent( |
551 Handle<Script> script, bool before); | 552 Handle<Script> script, v8::DebugEvent type); |
552 MUST_USE_RESULT MaybeHandle<Object> MakeScriptCollectedEvent(int id); | 553 MUST_USE_RESULT MaybeHandle<Object> MakeScriptCollectedEvent(int id); |
553 | 554 |
554 // Mirror cache handling. | 555 // Mirror cache handling. |
555 void ClearMirrorCache(); | 556 void ClearMirrorCache(); |
556 | 557 |
557 // Returns a promise if it does not have a reject handler. | 558 // Returns a promise if it does not have a reject handler. |
558 Handle<Object> GetPromiseForUncaughtException(); | 559 Handle<Object> GetPromiseForUncaughtException(); |
559 | 560 |
560 void CallEventCallback(v8::DebugEvent event, | 561 void CallEventCallback(v8::DebugEvent event, |
561 Handle<Object> exec_state, | 562 Handle<Object> exec_state, |
(...skipping 207 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
769 // several frames above. | 770 // several frames above. |
770 // There is no calling conventions here, because it never actually gets | 771 // There is no calling conventions here, because it never actually gets |
771 // called, it only gets returned to. | 772 // called, it only gets returned to. |
772 static void GenerateFrameDropperLiveEdit(MacroAssembler* masm); | 773 static void GenerateFrameDropperLiveEdit(MacroAssembler* masm); |
773 }; | 774 }; |
774 | 775 |
775 | 776 |
776 } } // namespace v8::internal | 777 } } // namespace v8::internal |
777 | 778 |
778 #endif // V8_DEBUG_H_ | 779 #endif // V8_DEBUG_H_ |
OLD | NEW |