Version 2.2.16.

Remove the SetExternalStringDiposeCallback API. Changed the disposal of external string resources to call a virtual Dispose method on the resource.

Added support for more precise break points when debugging and stepping.

Memory usage improvements on all platforms.


git-svn-id: http://v8.googlecode.com/svn/trunk@4829 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
diff --git a/src/heap-inl.h b/src/heap-inl.h
index feda2d1..cc558b8 100644
--- a/src/heap-inl.h
+++ b/src/heap-inl.h
@@ -118,11 +118,9 @@
           ExternalString::kResourceOffset -
           kHeapObjectTag);
 
-  // Dispose of the C++ object.
-  if (external_string_dispose_callback_ != NULL) {
-    external_string_dispose_callback_(*resource_addr);
-  } else {
-    delete *resource_addr;
+  // Dispose of the C++ object if it has not already been disposed.
+  if (*resource_addr != NULL) {
+    (*resource_addr)->Dispose();
   }
 
   // Clear the resource pointer in the string.