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

Unified Diff: runtime/lib/date.cc

Issue 1493033003: Add microsecond support to DateTime. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Address comment. Created 5 years 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 | « no previous file | runtime/lib/date_patch.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/lib/date.cc
diff --git a/runtime/lib/date.cc b/runtime/lib/date.cc
index 67891b9fcb45622f684714b12c33065fb72eb954..cf92809836bac21d94b09a1861a2534585972dd0 100644
--- a/runtime/lib/date.cc
+++ b/runtime/lib/date.cc
@@ -14,7 +14,7 @@ namespace dart {
static int32_t kMaxAllowedSeconds = 2100000000;
-DEFINE_NATIVE_ENTRY(DateNatives_timeZoneName, 1) {
+DEFINE_NATIVE_ENTRY(DateTime_timeZoneName, 1) {
GET_NON_NULL_NATIVE_ARGUMENT(
Integer, dart_seconds, arguments->NativeArgAt(0));
int64_t seconds = dart_seconds.AsInt64Value();
@@ -26,7 +26,7 @@ DEFINE_NATIVE_ENTRY(DateNatives_timeZoneName, 1) {
}
-DEFINE_NATIVE_ENTRY(DateNatives_timeZoneOffsetInSeconds, 1) {
+DEFINE_NATIVE_ENTRY(DateTime_timeZoneOffsetInSeconds, 1) {
GET_NON_NULL_NATIVE_ARGUMENT(
Integer, dart_seconds, arguments->NativeArgAt(0));
int64_t seconds = dart_seconds.AsInt64Value();
@@ -38,14 +38,14 @@ DEFINE_NATIVE_ENTRY(DateNatives_timeZoneOffsetInSeconds, 1) {
}
-DEFINE_NATIVE_ENTRY(DateNatives_localTimeZoneAdjustmentInSeconds, 0) {
+DEFINE_NATIVE_ENTRY(DateTime_localTimeZoneAdjustmentInSeconds, 0) {
int adjustment = OS::GetLocalTimeZoneAdjustmentInSeconds();
return Integer::New(adjustment);
}
-DEFINE_NATIVE_ENTRY(DateNatives_currentTimeMillis, 0) {
- return Integer::New(OS::GetCurrentTimeMillis());
+DEFINE_NATIVE_ENTRY(DateTime_currentTimeMicros, 0) {
+ return Integer::New(OS::GetCurrentTimeMicros());
}
} // namespace dart
« no previous file with comments | « no previous file | runtime/lib/date_patch.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698