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

Unified Diff: src/heap.cc

Issue 68723002: Implement Math.random() purely in JavaScript. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Comments only Created 7 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
« no previous file with comments | « src/globals.h ('k') | src/hydrogen.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/heap.cc
diff --git a/src/heap.cc b/src/heap.cc
index dfb24783d016d6d2c5cde5106e93df6ce399cf5d..c21f5fea92406a645fb436f4da03ce74182e0683 100644
--- a/src/heap.cc
+++ b/src/heap.cc
@@ -1765,7 +1765,9 @@ struct WeakListVisitor<Context> {
}
}
- static void VisitPhantomObject(Heap*, Context*) {
+ static void VisitPhantomObject(Heap*, Context* context) {
+ // A bit of a hack, see the comment at the end of Genesis::Genesis().
+ delete[] reinterpret_cast<uint32_t*>(context->random_state());
}
static int WeakNextOffset() {
« no previous file with comments | « src/globals.h ('k') | src/hydrogen.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698