Revision: 17372
Author: [email protected]
Date: Thu Oct 24 11:59:09 2013 UTC
Log: Fix shared library build after r17368.
[email protected]
Review URL: https://codereview.chromium.org/40033002
http://code.google.com/p/v8/source/detail?r=17372
Modified:
/branches/bleeding_edge/src/d8.cc
/branches/bleeding_edge/src/d8.h
=======================================
--- /branches/bleeding_edge/src/d8.cc Thu Oct 24 10:48:18 2013 UTC
+++ /branches/bleeding_edge/src/d8.cc Thu Oct 24 11:59:09 2013 UTC
@@ -160,13 +160,13 @@
CounterCollection Shell::local_counters_;
CounterCollection* Shell::counters_ = &local_counters_;
i::Mutex Shell::context_mutex_;
+const i::TimeTicks Shell::kInitialTicks =
i::TimeTicks::HighResolutionNow();
Persistent<Context> Shell::utility_context_;
#endif // V8_SHARED
Persistent<Context> Shell::evaluation_context_;
ShellOptions Shell::options;
const char* Shell::kPrompt = "d8> ";
-const i::TimeTicks Shell::kInitialTicks =
i::TimeTicks::HighResolutionNow();
const int MB = 1024 * 1024;
@@ -290,11 +290,13 @@
}
+#ifndef V8_SHARED
// performance.now() returns a time stamp as double, measured in
milliseconds.
void Shell::PerformanceNow(const v8::FunctionCallbackInfo<v8::Value>&
args) {
i::TimeDelta delta = i::TimeTicks::HighResolutionNow() - kInitialTicks;
args.GetReturnValue().Set(delta.InMillisecondsF());
}
+#endif // V8_SHARED
// Realm.current() returns the index of the currently active realm.
@@ -880,10 +882,12 @@
RealmSharedGet, RealmSharedSet);
global_template->Set(String::New("Realm"), realm_template);
+#ifndef V8_SHARED
Handle<ObjectTemplate> performance_template = ObjectTemplate::New();
performance_template->Set(String::New("now"),
FunctionTemplate::New(PerformanceNow));
global_template->Set(String::New("performance"), performance_template);
+#endif // V8_SHARED
#if !defined(V8_SHARED) && !defined(_WIN32) && !defined(_WIN64)
Handle<ObjectTemplate> os_templ = ObjectTemplate::New();
=======================================
--- /branches/bleeding_edge/src/d8.h Thu Oct 24 10:48:18 2013 UTC
+++ /branches/bleeding_edge/src/d8.h Thu Oct 24 11:59:09 2013 UTC
@@ -302,9 +302,10 @@
Handle<String> command);
static void DispatchDebugMessages();
#endif // ENABLE_DEBUGGER_SUPPORT
+
+ static void PerformanceNow(const v8::FunctionCallbackInfo<v8::Value>&
args);
#endif // V8_SHARED
- static void PerformanceNow(const v8::FunctionCallbackInfo<v8::Value>&
args);
static void RealmCurrent(const v8::FunctionCallbackInfo<v8::Value>&
args);
static void RealmOwner(const v8::FunctionCallbackInfo<v8::Value>& args);
static void RealmGlobal(const v8::FunctionCallbackInfo<v8::Value>& args);
@@ -382,7 +383,6 @@
static const char* kPrompt;
static ShellOptions options;
- static const i::TimeTicks kInitialTicks;
private:
static Persistent<Context> evaluation_context_;
@@ -395,6 +395,7 @@
static CounterCollection* counters_;
static i::OS::MemoryMappedFile* counters_file_;
static i::Mutex context_mutex_;
+ static const i::TimeTicks kInitialTicks;
static Counter* GetCounter(const char* name, bool is_histogram);
static void InstallUtilityScript(Isolate* isolate);
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.