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

Side by Side Diff: src/handles.cc

Issue 3165016: Allow allocation in FailedAccessCheckCallback to allow embedders to... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 10 years, 4 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | src/objects.cc » ('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 2009 the V8 project authors. All rights reserved. 1 // Copyright 2009 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 619 matching lines...) Expand 10 before | Expand all | Expand 10 after
630 JSFunction::cast(arguments_boilerplate->map()->constructor())); 630 JSFunction::cast(arguments_boilerplate->map()->constructor()));
631 631
632 // Only collect keys if access is permitted. 632 // Only collect keys if access is permitted.
633 for (Handle<Object> p = object; 633 for (Handle<Object> p = object;
634 *p != Heap::null_value(); 634 *p != Heap::null_value();
635 p = Handle<Object>(p->GetPrototype())) { 635 p = Handle<Object>(p->GetPrototype())) {
636 Handle<JSObject> current(JSObject::cast(*p)); 636 Handle<JSObject> current(JSObject::cast(*p));
637 637
638 // Check access rights if required. 638 // Check access rights if required.
639 if (current->IsAccessCheckNeeded() && 639 if (current->IsAccessCheckNeeded() &&
640 !Top::MayNamedAccess(*current, Heap::undefined_value(), 640 !Top::MayNamedAccess(*current, Heap::undefined_value(),
641 v8::ACCESS_KEYS)) { 641 v8::ACCESS_KEYS)) {
642 Top::ReportFailedAccessCheck(*current, v8::ACCESS_KEYS); 642 Top::ReportFailedAccessCheck(*current, v8::ACCESS_KEYS);
643 break; 643 break;
644 } 644 }
645 645
646 // Compute the element keys. 646 // Compute the element keys.
647 Handle<FixedArray> element_keys = 647 Handle<FixedArray> element_keys =
648 Factory::NewFixedArray(current->NumberOfEnumElements()); 648 Factory::NewFixedArray(current->NumberOfEnumElements());
649 current->GetEnumElementKeys(*element_keys); 649 current->GetEnumElementKeys(*element_keys);
650 content = UnionOfKeys(content, element_keys); 650 content = UnionOfKeys(content, element_keys);
651 651
(...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after
821 821
822 OptimizedObjectForAddingMultipleProperties:: 822 OptimizedObjectForAddingMultipleProperties::
823 ~OptimizedObjectForAddingMultipleProperties() { 823 ~OptimizedObjectForAddingMultipleProperties() {
824 // Reoptimize the object to allow fast property access. 824 // Reoptimize the object to allow fast property access.
825 if (has_been_transformed_) { 825 if (has_been_transformed_) {
826 TransformToFastProperties(object_, unused_property_fields_); 826 TransformToFastProperties(object_, unused_property_fields_);
827 } 827 }
828 } 828 }
829 829
830 } } // namespace v8::internal 830 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | src/objects.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698