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

Unified Diff: src/objects.h

Issue 1479543002: [proxies] Implement [[Delete]]. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix typo Created 5 years, 1 month 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 side-by-side diff with in-line comments
Download patch
Index: src/objects.h
diff --git a/src/objects.h b/src/objects.h
index dba897d42cdc75920c9142e9e0b0aa67ce68a0d8..69caca7a8f4756034cf2605630d0445436ad30e0 100644
--- a/src/objects.h
+++ b/src/objects.h
@@ -1811,16 +1811,16 @@ class JSReceiver: public HeapObject {
MUST_USE_RESULT static inline Maybe<bool> HasOwnElement(
Handle<JSReceiver> object, uint32_t index);
- // Implementation of [[Delete]], ECMA-262 5th edition, section 8.12.7.
- MUST_USE_RESULT static MaybeHandle<Object> DeletePropertyOrElement(
+ // Implementation of ES6 [[Delete]]
+ MUST_USE_RESULT static Maybe<bool> DeletePropertyOrElement(
Handle<JSReceiver> object, Handle<Name> name,
LanguageMode language_mode = SLOPPY);
- MUST_USE_RESULT static MaybeHandle<Object> DeleteProperty(
+ MUST_USE_RESULT static Maybe<bool> DeleteProperty(
Handle<JSReceiver> object, Handle<Name> name,
LanguageMode language_mode = SLOPPY);
- MUST_USE_RESULT static MaybeHandle<Object> DeleteProperty(
- LookupIterator* it, LanguageMode language_mode);
- MUST_USE_RESULT static MaybeHandle<Object> DeleteElement(
+ MUST_USE_RESULT static Maybe<bool> DeleteProperty(LookupIterator* it,
+ LanguageMode language_mode);
+ MUST_USE_RESULT static Maybe<bool> DeleteElement(
Handle<JSReceiver> object, uint32_t index,
LanguageMode language_mode = SLOPPY);
@@ -2510,7 +2510,7 @@ class JSObject: public JSReceiver {
Handle<Object> value,
PropertyAttributes attributes);
- MUST_USE_RESULT static MaybeHandle<Object> DeletePropertyWithInterceptor(
+ MUST_USE_RESULT static Maybe<bool> DeletePropertyWithInterceptor(
LookupIterator* it);
bool ReferencesObjectFromElements(FixedArray* elements,
@@ -9546,6 +9546,10 @@ class JSProxy: public JSReceiver {
Handle<Object> key, PropertyDescriptor* desc,
ShouldThrow should_throw);
+ // ES6 9.5.10 (when passed SLOPPY)
+ MUST_USE_RESULT static Maybe<bool> DeletePropertyOrElement(
+ Handle<JSProxy> proxy, Handle<Name> name, LanguageMode language_mode);
+
MUST_USE_RESULT static MaybeHandle<Object> GetPropertyWithHandler(
Handle<JSProxy> proxy,
Handle<Object> receiver,
@@ -9601,9 +9605,6 @@ class JSProxy: public JSReceiver {
MUST_USE_RESULT static Maybe<bool> HasPropertyWithHandler(
Handle<JSProxy> proxy, Handle<Name> name);
- MUST_USE_RESULT static MaybeHandle<Object> DeletePropertyWithHandler(
- Handle<JSProxy> proxy, Handle<Name> name, LanguageMode language_mode);
-
DISALLOW_IMPLICIT_CONSTRUCTORS(JSProxy);
};
« no previous file with comments | « src/messages.h ('k') | src/objects.cc » ('j') | test/mjsunit/harmony/proxies-delete-property.js » ('J')

Powered by Google App Engine
This is Rietveld 408576698