Chromium Code Reviews| Index: include/v8.h |
| diff --git a/include/v8.h b/include/v8.h |
| index 8fc9149671a9795d3a797e543d8f8ae4f29c3ba6..e65a374966f6fa6ef5ed3b3d594fe97512e5a312 100644 |
| --- a/include/v8.h |
| +++ b/include/v8.h |
| @@ -4543,11 +4543,25 @@ typedef void (*GenericNamedPropertySetterCallback)( |
| Local<Name> property, Local<Value> value, |
| const PropertyCallbackInfo<Value>& info); |
| - |
| /** |
| - * Returns a non-empty handle if the interceptor intercepts the request. |
| - * The result is an integer encoding property attributes (like v8::None, |
| - * v8::DontEnum, etc.) |
| + * Intercepts all requests that query the attributes of the |
| + * property, e.g., getOwnPropertyDescriptor(), propertyIsEnumerable(), and |
| + * defineProperty(). |
| + * |
| + * Use `info.GetReturnValue().Set(value)` to set the property attributes. The |
| + * value is an interger encoding a `v8::PropertyAttribute`. |
| + * |
| + * \param property The name of the property for which the request was |
| + * intercepted. |
| + * \param info Information about the intercepted request, such as |
| + * isolate, receiver, return value, or whether running in `'use strict'` mode. |
| + * See `PropertyCallbackInfo`. |
| + * |
| + * \note hasOwnProperty() can trigger this interceptor, but for optimization |
| + * reasons it is not guaranteed to. |
|
jochen (gone - plz use gerrit)
2016/08/29 12:52:35
wut? :-/
Franzi
2016/08/31 11:18:36
Is this version better or should we leave out the
jochen (gone - plz use gerrit)
2016/08/31 14:37:49
ah, so you mean that hasOwnProperty might or might
|
| + * |
| + * See also |
| + * `ObjectTemplate::SetNamedPropertyHandler.` |
| */ |
| typedef void (*GenericNamedPropertyQueryCallback)( |
| Local<Name> property, const PropertyCallbackInfo<Integer>& info); |