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

Unified Diff: include/v8.h

Issue 155635: Introduce faster utilty methods for storing and retrieving native pointers (Closed)
Patch Set: last pass Created 11 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/api.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/v8.h
diff --git a/include/v8.h b/include/v8.h
index 8f22c81b651ef6a07c8e2e87c0b1a0e7743a9e39..0859234b617c3676a33ed569e5c9c77ccb580deb 100644
--- a/include/v8.h
+++ b/include/v8.h
@@ -1113,6 +1113,13 @@ class V8EXPORT Object : public Value {
/** Sets the value in an internal field. */
void SetInternalField(int index, Handle<Value> value);
+ // The two functions below do not perform index bounds checks and
+ // they do not check that the VM is still running. Use with caution.
+ /** Gets a native pointer from an internal field. */
+ void* GetPointerFromInternalField(int index);
+ /** Sets a native pointer in an internal field. */
+ void SetPointerInInternalField(int index, void* value);
+
// Testers for local properties.
bool HasRealNamedProperty(Handle<String> key);
bool HasRealIndexedProperty(uint32_t index);
« no previous file with comments | « no previous file | src/api.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698