Index: src/snapshot/code-serializer.cc |
diff --git a/src/snapshot/code-serializer.cc b/src/snapshot/code-serializer.cc |
index 48813f5c615988fab98f9b6eaa6005962bca6ac3..cd8b1f1a0ea8b2d5892945096021918f953b96dd 100644 |
--- a/src/snapshot/code-serializer.cc |
+++ b/src/snapshot/code-serializer.cc |
@@ -14,6 +14,7 @@ |
#include "src/snapshot/deserializer.h" |
#include "src/snapshot/snapshot.h" |
#include "src/version.h" |
+#include "src/visitors.h" |
#include "src/wasm/wasm-module.h" |
#include "src/wasm/wasm-objects.h" |
@@ -50,7 +51,7 @@ ScriptData* CodeSerializer::Serialize(Isolate* isolate, |
ScriptData* CodeSerializer::Serialize(Handle<HeapObject> obj) { |
DisallowHeapAllocation no_gc; |
- VisitPointer(Handle<Object>::cast(obj).location()); |
+ VisitRootPointer(Root::kHandleScope, Handle<Object>::cast(obj).location()); |
SerializeDeferredObjects(); |
Pad(); |