Index: include/v8.h |
diff --git a/include/v8.h b/include/v8.h |
index 79f4478ea6f626ff297314b4ed227d5dc088abed..de2733838ff5abcdb05f5f84db5716440b6dd886 100644 |
--- a/include/v8.h |
+++ b/include/v8.h |
@@ -819,7 +819,7 @@ class V8_EXPORT HandleScope { |
* value. |
*/ |
template<class T> |
-struct V8_EXPORT Maybe { |
+struct Maybe { |
Maybe() : has_value(false) {} |
explicit Maybe(T t) : has_value(true), value(t) {} |
Maybe(bool has, T t) : has_value(has), value(t) {} |
@@ -2364,7 +2364,7 @@ class FunctionCallbackInfo { |
V8_INLINE Isolate* GetIsolate() const; |
V8_INLINE ReturnValue<T> GetReturnValue() const; |
// This shouldn't be public, but the arm compiler needs it. |
- static const int kArgsLength = 7; |
+ static const int kArgsLength = 6; |
protected: |
friend class internal::FunctionCallbackArguments; |
@@ -2375,7 +2375,6 @@ class FunctionCallbackInfo { |
static const int kDataIndex = -3; |
static const int kCalleeIndex = -4; |
static const int kHolderIndex = -5; |
- static const int kContextSaveIndex = -6; |
V8_INLINE FunctionCallbackInfo(internal::Object** implicit_args, |
internal::Object** values, |
@@ -3871,6 +3870,8 @@ enum GCCallbackFlags { |
typedef void (*GCPrologueCallback)(GCType type, GCCallbackFlags flags); |
typedef void (*GCEpilogueCallback)(GCType type, GCCallbackFlags flags); |
+typedef void (*GCCallback)(); |
+ |
/** |
* Collection of V8 heap information. |
@@ -4054,51 +4055,6 @@ class V8_EXPORT Isolate { |
void SetReference(const Persistent<Object>& parent, |
const Persistent<Value>& child); |
- typedef void (*GCPrologueCallback)(Isolate* isolate, |
- GCType type, |
- GCCallbackFlags flags); |
- typedef void (*GCEpilogueCallback)(Isolate* isolate, |
- GCType type, |
- GCCallbackFlags flags); |
- |
- /** |
- * Enables the host application to receive a notification before a |
- * garbage collection. Allocations are not allowed in the |
- * callback function, you therefore cannot manipulate objects (set |
- * or delete properties for example) since it is possible such |
- * operations will result in the allocation of objects. It is possible |
- * to specify the GCType filter for your callback. But it is not possible to |
- * register the same callback function two times with different |
- * GCType filters. |
- */ |
- void AddGCPrologueCallback( |
- GCPrologueCallback callback, GCType gc_type_filter = kGCTypeAll); |
- |
- /** |
- * This function removes callback which was installed by |
- * AddGCPrologueCallback function. |
- */ |
- void RemoveGCPrologueCallback(GCPrologueCallback callback); |
- |
- /** |
- * Enables the host application to receive a notification after a |
- * garbage collection. Allocations are not allowed in the |
- * callback function, you therefore cannot manipulate objects (set |
- * or delete properties for example) since it is possible such |
- * operations will result in the allocation of objects. It is possible |
- * to specify the GCType filter for your callback. But it is not possible to |
- * register the same callback function two times with different |
- * GCType filters. |
- */ |
- void AddGCEpilogueCallback( |
- GCEpilogueCallback callback, GCType gc_type_filter = kGCTypeAll); |
- |
- /** |
- * This function removes callback which was installed by |
- * AddGCEpilogueCallback function. |
- */ |
- void RemoveGCEpilogueCallback(GCEpilogueCallback callback); |
- |
private: |
Isolate(); |
Isolate(const Isolate&); |
@@ -4456,6 +4412,16 @@ class V8_EXPORT V8 { |
static void RemoveGCPrologueCallback(GCPrologueCallback callback); |
/** |
+ * The function is deprecated. Please use AddGCPrologueCallback instead. |
+ * Enables the host application to receive a notification before a |
+ * garbage collection. Allocations are not allowed in the |
+ * callback function, you therefore cannot manipulate objects (set |
+ * or delete properties for example) since it is possible such |
+ * operations will result in the allocation of objects. |
+ */ |
+ V8_DEPRECATED(static void SetGlobalGCPrologueCallback(GCCallback)); |
+ |
+ /** |
* Enables the host application to receive a notification after a |
* garbage collection. Allocations are not allowed in the |
* callback function, you therefore cannot manipulate objects (set |
@@ -4475,6 +4441,16 @@ class V8_EXPORT V8 { |
static void RemoveGCEpilogueCallback(GCEpilogueCallback callback); |
/** |
+ * The function is deprecated. Please use AddGCEpilogueCallback instead. |
+ * Enables the host application to receive a notification after a |
+ * major garbage collection. Allocations are not allowed in the |
+ * callback function, you therefore cannot manipulate objects (set |
+ * or delete properties for example) since it is possible such |
+ * operations will result in the allocation of objects. |
+ */ |
+ V8_DEPRECATED(static void SetGlobalGCEpilogueCallback(GCCallback)); |
+ |
+ /** |
* Enables the host application to provide a mechanism to be notified |
* and perform custom logging when V8 Allocates Executable Memory. |
*/ |