| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 560 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 571 v8::TryCatch* catcher() { | 571 v8::TryCatch* catcher() { |
| 572 return thread_local_top_.catcher_; | 572 return thread_local_top_.catcher_; |
| 573 } | 573 } |
| 574 void set_catcher(v8::TryCatch* catcher) { | 574 void set_catcher(v8::TryCatch* catcher) { |
| 575 thread_local_top_.catcher_ = catcher; | 575 thread_local_top_.catcher_ = catcher; |
| 576 } | 576 } |
| 577 | 577 |
| 578 MaybeObject** scheduled_exception_address() { | 578 MaybeObject** scheduled_exception_address() { |
| 579 return &thread_local_top_.scheduled_exception_; | 579 return &thread_local_top_.scheduled_exception_; |
| 580 } | 580 } |
| 581 |
| 582 Address pending_message_obj_address() { |
| 583 return reinterpret_cast<Address>(&thread_local_top_.pending_message_obj_); |
| 584 } |
| 585 |
| 581 MaybeObject* scheduled_exception() { | 586 MaybeObject* scheduled_exception() { |
| 582 ASSERT(has_scheduled_exception()); | 587 ASSERT(has_scheduled_exception()); |
| 583 return thread_local_top_.scheduled_exception_; | 588 return thread_local_top_.scheduled_exception_; |
| 584 } | 589 } |
| 585 bool has_scheduled_exception() { | 590 bool has_scheduled_exception() { |
| 586 return thread_local_top_.scheduled_exception_ != heap_.the_hole_value(); | 591 return thread_local_top_.scheduled_exception_ != heap_.the_hole_value(); |
| 587 } | 592 } |
| 588 void clear_scheduled_exception() { | 593 void clear_scheduled_exception() { |
| 589 thread_local_top_.scheduled_exception_ = heap_.the_hole_value(); | 594 thread_local_top_.scheduled_exception_ = heap_.the_hole_value(); |
| 590 } | 595 } |
| (...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 701 | 706 |
| 702 void SetFailedAccessCheckCallback(v8::FailedAccessCheckCallback callback); | 707 void SetFailedAccessCheckCallback(v8::FailedAccessCheckCallback callback); |
| 703 void ReportFailedAccessCheck(JSObject* receiver, v8::AccessType type); | 708 void ReportFailedAccessCheck(JSObject* receiver, v8::AccessType type); |
| 704 | 709 |
| 705 // Exception throwing support. The caller should use the result | 710 // Exception throwing support. The caller should use the result |
| 706 // of Throw() as its return value. | 711 // of Throw() as its return value. |
| 707 Failure* Throw(Object* exception, MessageLocation* location = NULL); | 712 Failure* Throw(Object* exception, MessageLocation* location = NULL); |
| 708 // Re-throw an exception. This involves no error reporting since | 713 // Re-throw an exception. This involves no error reporting since |
| 709 // error reporting was handled when the exception was thrown | 714 // error reporting was handled when the exception was thrown |
| 710 // originally. | 715 // originally. |
| 711 Failure* ReThrow(MaybeObject* exception, MessageLocation* location = NULL); | 716 Failure* ReThrow(MaybeObject* exception); |
| 712 void ScheduleThrow(Object* exception); | 717 void ScheduleThrow(Object* exception); |
| 713 void ReportPendingMessages(); | 718 void ReportPendingMessages(); |
| 714 Failure* ThrowIllegalOperation(); | 719 Failure* ThrowIllegalOperation(); |
| 715 | 720 |
| 716 // Promote a scheduled exception to pending. Asserts has_scheduled_exception. | 721 // Promote a scheduled exception to pending. Asserts has_scheduled_exception. |
| 717 Failure* PromoteScheduledException(); | 722 Failure* PromoteScheduledException(); |
| 718 void DoThrow(Object* exception, MessageLocation* location); | 723 void DoThrow(Object* exception, MessageLocation* location); |
| 719 // Checks if exception should be reported and finds out if it's | 724 // Checks if exception should be reported and finds out if it's |
| 720 // caught externally. | 725 // caught externally. |
| 721 bool ShouldReportException(bool* can_be_caught_externally, | 726 bool ShouldReportException(bool* can_be_caught_externally, |
| (...skipping 684 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1406 | 1411 |
| 1407 // Mark the global context with out of memory. | 1412 // Mark the global context with out of memory. |
| 1408 inline void Context::mark_out_of_memory() { | 1413 inline void Context::mark_out_of_memory() { |
| 1409 global_context()->set_out_of_memory(HEAP->true_value()); | 1414 global_context()->set_out_of_memory(HEAP->true_value()); |
| 1410 } | 1415 } |
| 1411 | 1416 |
| 1412 | 1417 |
| 1413 } } // namespace v8::internal | 1418 } } // namespace v8::internal |
| 1414 | 1419 |
| 1415 #endif // V8_ISOLATE_H_ | 1420 #endif // V8_ISOLATE_H_ |
| OLD | NEW |