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

Side by Side Diff: src/factory.cc

Issue 225283005: Return MaybeHandle from SetProperty. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: addressed comments Created 6 years, 8 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 | « src/factory.h ('k') | src/handles.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 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 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 "factory.h" 5 #include "factory.h"
6 6
7 #include "isolate-inl.h" 7 #include "isolate-inl.h"
8 8
9 namespace v8 { 9 namespace v8 {
10 namespace internal { 10 namespace internal {
(...skipping 793 matching lines...) Expand 10 before | Expand all | Expand 10 after
804 ASSERT(object_function->has_initial_map()); 804 ASSERT(object_function->has_initial_map());
805 new_map = Map::Copy(handle(object_function->initial_map())); 805 new_map = Map::Copy(handle(object_function->initial_map()));
806 } 806 }
807 807
808 Handle<JSObject> prototype = NewJSObjectFromMap(new_map); 808 Handle<JSObject> prototype = NewJSObjectFromMap(new_map);
809 809
810 if (!function->shared()->is_generator()) { 810 if (!function->shared()->is_generator()) {
811 JSObject::SetLocalPropertyIgnoreAttributes(prototype, 811 JSObject::SetLocalPropertyIgnoreAttributes(prototype,
812 constructor_string(), 812 constructor_string(),
813 function, 813 function,
814 DONT_ENUM); 814 DONT_ENUM).Assert();
815 } 815 }
816 816
817 return prototype; 817 return prototype;
818 } 818 }
819 819
820 820
821 Handle<FixedArray> Factory::CopyFixedArray(Handle<FixedArray> array) { 821 Handle<FixedArray> Factory::CopyFixedArray(Handle<FixedArray> array) {
822 CALL_HEAP_FUNCTION(isolate(), array->Copy(), FixedArray); 822 CALL_HEAP_FUNCTION(isolate(), array->Copy(), FixedArray);
823 } 823 }
824 824
(...skipping 1123 matching lines...) Expand 10 before | Expand all | Expand 10 after
1948 if (name->Equals(h->infinity_string())) return infinity_value(); 1948 if (name->Equals(h->infinity_string())) return infinity_value();
1949 return Handle<Object>::null(); 1949 return Handle<Object>::null();
1950 } 1950 }
1951 1951
1952 1952
1953 Handle<Object> Factory::ToBoolean(bool value) { 1953 Handle<Object> Factory::ToBoolean(bool value) {
1954 return value ? true_value() : false_value(); 1954 return value ? true_value() : false_value();
1955 } 1955 }
1956 1956
1957 } } // namespace v8::internal 1957 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/factory.h ('k') | src/handles.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698