Index: src/v8.cc |
diff --git a/src/v8.cc b/src/v8.cc |
index 17007a2a2cffddf0960119374cdb6f1857e5f3e9..92c45fa42ab90f50bc88360275a9874040e09785 100644 |
--- a/src/v8.cc |
+++ b/src/v8.cc |
@@ -52,6 +52,7 @@ V8_DECLARE_ONCE(init_once); |
List<CallCompletedCallback>* V8::call_completed_callbacks_ = NULL; |
v8::ArrayBuffer::Allocator* V8::array_buffer_allocator_ = NULL; |
+v8::Platform* V8::platform_ = NULL; |
bool V8::Initialize(Deserializer* des) { |
@@ -194,4 +195,23 @@ void V8::InitializeOncePerProcess() { |
CallOnce(&init_once, &InitializeOncePerProcessImpl); |
} |
+ |
+void V8::InitializePlatform(v8::Platform* platform) { |
+ ASSERT(!platform_); |
+ ASSERT(platform); |
+ platform_ = platform; |
+} |
+ |
+ |
+void V8::ShutdownPlatform() { |
+ ASSERT(platform_); |
+ platform_ = NULL; |
+} |
+ |
+ |
+v8::Platform* V8::GetCurrentPlatform() { |
+ ASSERT(platform_); |
+ return platform_; |
+} |
+ |
} } // namespace v8::internal |