Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2)

Side by Side Diff: src/isolate.cc

Issue 952483002: NewError no longer returns a MaybeObject. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@reland
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/isolate.h ('k') | src/json-parser.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #include <stdlib.h> 5 #include <stdlib.h>
6 6
7 #include <fstream> // NOLINT(readability/streams) 7 #include <fstream> // NOLINT(readability/streams)
8 #include <sstream> 8 #include <sstream>
9 9
10 #include "src/v8.h" 10 #include "src/v8.h"
(...skipping 721 matching lines...) Expand 10 before | Expand all | Expand 10 after
732 if (data_obj == isolate->heap()->undefined_value()) return NULL; 732 if (data_obj == isolate->heap()->undefined_value()) return NULL;
733 733
734 return AccessCheckInfo::cast(data_obj); 734 return AccessCheckInfo::cast(data_obj);
735 } 735 }
736 736
737 737
738 void Isolate::ReportFailedAccessCheck(Handle<JSObject> receiver, 738 void Isolate::ReportFailedAccessCheck(Handle<JSObject> receiver,
739 v8::AccessType type) { 739 v8::AccessType type) {
740 if (!thread_local_top()->failed_access_check_callback_) { 740 if (!thread_local_top()->failed_access_check_callback_) {
741 Handle<String> message = factory()->InternalizeUtf8String("no access"); 741 Handle<String> message = factory()->InternalizeUtf8String("no access");
742 Handle<Object> error; 742 ScheduleThrow(*factory()->NewTypeError(message));
743 ASSIGN_RETURN_ON_EXCEPTION_VALUE(
744 this, error, factory()->NewTypeError(message), /* void */);
745 ScheduleThrow(*error);
746 return; 743 return;
747 } 744 }
748 745
749 DCHECK(receiver->IsAccessCheckNeeded()); 746 DCHECK(receiver->IsAccessCheckNeeded());
750 DCHECK(context()); 747 DCHECK(context());
751 748
752 // Get the data object from access check info. 749 // Get the data object from access check info.
753 HandleScope scope(this); 750 HandleScope scope(this);
754 Handle<Object> data; 751 Handle<Object> data;
755 { DisallowHeapAllocation no_gc; 752 { DisallowHeapAllocation no_gc;
(...skipping 1879 matching lines...) Expand 10 before | Expand all | Expand 10 after
2635 if (prev_ && prev_->Intercept(flag)) return true; 2632 if (prev_ && prev_->Intercept(flag)) return true;
2636 // Then check whether this scope intercepts. 2633 // Then check whether this scope intercepts.
2637 if ((flag & intercept_mask_)) { 2634 if ((flag & intercept_mask_)) {
2638 intercepted_flags_ |= flag; 2635 intercepted_flags_ |= flag;
2639 return true; 2636 return true;
2640 } 2637 }
2641 return false; 2638 return false;
2642 } 2639 }
2643 2640
2644 } } // namespace v8::internal 2641 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/isolate.h ('k') | src/json-parser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698