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

Side by Side Diff: src/objects.h

Issue 1809233002: Throw exceptions from CreateDataProperty when should_throw (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: brackets Created 4 years, 9 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 | « 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 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 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_OBJECTS_H_ 5 #ifndef V8_OBJECTS_H_
6 #define V8_OBJECTS_H_ 6 #define V8_OBJECTS_H_
7 7
8 #include <iosfwd> 8 #include <iosfwd>
9 9
10 #include "src/assert-scope.h" 10 #include "src/assert-scope.h"
(...skipping 2085 matching lines...) Expand 10 before | Expand all | Expand 10 after
2096 // Equivalent to one of the above depending on whether |name| can be converted 2096 // Equivalent to one of the above depending on whether |name| can be converted
2097 // to an array index. 2097 // to an array index.
2098 MUST_USE_RESULT static MaybeHandle<Object> 2098 MUST_USE_RESULT static MaybeHandle<Object>
2099 DefinePropertyOrElementIgnoreAttributes(Handle<JSObject> object, 2099 DefinePropertyOrElementIgnoreAttributes(Handle<JSObject> object,
2100 Handle<Name> name, 2100 Handle<Name> name,
2101 Handle<Object> value, 2101 Handle<Object> value,
2102 PropertyAttributes attributes = NONE); 2102 PropertyAttributes attributes = NONE);
2103 2103
2104 // Adds or reconfigures a property to attributes NONE. It will fail when it 2104 // Adds or reconfigures a property to attributes NONE. It will fail when it
2105 // cannot. 2105 // cannot.
2106 MUST_USE_RESULT static Maybe<bool> CreateDataProperty(LookupIterator* it, 2106 MUST_USE_RESULT static Maybe<bool> CreateDataProperty(
2107 Handle<Object> value); 2107 LookupIterator* it, Handle<Object> value,
2108 ShouldThrow should_throw = DONT_THROW);
2108 2109
2109 static void AddProperty(Handle<JSObject> object, Handle<Name> name, 2110 static void AddProperty(Handle<JSObject> object, Handle<Name> name,
2110 Handle<Object> value, PropertyAttributes attributes); 2111 Handle<Object> value, PropertyAttributes attributes);
2111 2112
2112 MUST_USE_RESULT static Maybe<bool> AddDataElement( 2113 MUST_USE_RESULT static Maybe<bool> AddDataElement(
2113 Handle<JSObject> receiver, uint32_t index, Handle<Object> value, 2114 Handle<JSObject> receiver, uint32_t index, Handle<Object> value,
2114 PropertyAttributes attributes, ShouldThrow should_throw); 2115 PropertyAttributes attributes, ShouldThrow should_throw);
2115 MUST_USE_RESULT static MaybeHandle<Object> AddDataElement( 2116 MUST_USE_RESULT static MaybeHandle<Object> AddDataElement(
2116 Handle<JSObject> receiver, uint32_t index, Handle<Object> value, 2117 Handle<JSObject> receiver, uint32_t index, Handle<Object> value,
2117 PropertyAttributes attributes); 2118 PropertyAttributes attributes);
(...skipping 8770 matching lines...) Expand 10 before | Expand all | Expand 10 after
10888 } 10889 }
10889 return value; 10890 return value;
10890 } 10891 }
10891 }; 10892 };
10892 10893
10893 10894
10894 } // NOLINT, false-positive due to second-order macros. 10895 } // NOLINT, false-positive due to second-order macros.
10895 } // NOLINT, false-positive due to second-order macros. 10896 } // NOLINT, false-positive due to second-order macros.
10896 10897
10897 #endif // V8_OBJECTS_H_ 10898 #endif // V8_OBJECTS_H_
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