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

Unified Diff: lib/compiler/implementation/lib/coreimpl_patch.dart

Issue 11227055: Move DateImplementation from coreimpl to core, making it private. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 2 months 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 | « lib/compiler/implementation/lib/core_patch.dart ('k') | lib/core/date.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/compiler/implementation/lib/coreimpl_patch.dart
diff --git a/lib/compiler/implementation/lib/coreimpl_patch.dart b/lib/compiler/implementation/lib/coreimpl_patch.dart
index 9b6306416a565405394216416ce707b75dbb416c..d2a638d4ec982e9ab07b8336c7b118d7f6e1b903 100644
--- a/lib/compiler/implementation/lib/coreimpl_patch.dart
+++ b/lib/compiler/implementation/lib/coreimpl_patch.dart
@@ -69,65 +69,6 @@ patch class ListImplementation<E> {
}
-// Patch for Date implementation.
-// TODO(ager): Split out into date_patch.dart and allow #source
-// in patch files?
-patch class DateImplementation {
- patch DateImplementation(int year,
- int month,
- int day,
- int hour,
- int minute,
- int second,
- int millisecond,
- bool isUtc)
- : this.isUtc = checkNull(isUtc),
- millisecondsSinceEpoch = Primitives.valueFromDecomposedDate(
- year, month, day, hour, minute, second, millisecond, isUtc) {
- Primitives.lazyAsJsDate(this);
- }
-
- patch DateImplementation.now()
- : isUtc = false,
- millisecondsSinceEpoch = Primitives.dateNow() {
- Primitives.lazyAsJsDate(this);
- }
-
- patch static int _brokenDownDateToMillisecondsSinceEpoch(
- int year, int month, int day, int hour, int minute, int second,
- int millisecond, bool isUtc) {
- return Primitives.valueFromDecomposedDate(
- year, month, day, hour, minute, second, millisecond, isUtc);
- }
-
- patch String get timeZoneName {
- if (isUtc) return "UTC";
- return Primitives.getTimeZoneName(this);
- }
-
- patch Duration get timeZoneOffset {
- if (isUtc) return new Duration();
- return new Duration(minutes: Primitives.getTimeZoneOffsetInMinutes(this));
- }
-
- patch int get year => Primitives.getYear(this);
-
- patch int get month => Primitives.getMonth(this);
-
- patch int get day => Primitives.getDay(this);
-
- patch int get hour => Primitives.getHours(this);
-
- patch int get minute => Primitives.getMinutes(this);
-
- patch int get second => Primitives.getSeconds(this);
-
- patch int get millisecond => Primitives.getMilliseconds(this);
-
- patch int get weekday => Primitives.getWeekday(this);
-}
-
-
// Patch for Stopwatch implementation.
// TODO(ager): Split out into stopwatch_patch.dart and allow #source
// in patch files?
« no previous file with comments | « lib/compiler/implementation/lib/core_patch.dart ('k') | lib/core/date.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698