| Index: lib/compiler/implementation/lib/js_helper.dart
|
| diff --git a/lib/compiler/implementation/lib/js_helper.dart b/lib/compiler/implementation/lib/js_helper.dart
|
| index a961599608584f2ed9c6f2226afca6ad0a82006d..c2ef4a38f9d619dac533827d7aeb3eca8ca72cbd 100644
|
| --- a/lib/compiler/implementation/lib/js_helper.dart
|
| +++ b/lib/compiler/implementation/lib/js_helper.dart
|
| @@ -537,6 +537,10 @@ class Primitives {
|
| return JS('Date', r'#.date', receiver);
|
| }
|
|
|
| + // The getters for date and time parts below add a positive integer to ensure
|
| + // that the result is really an integer, because the JavaScript implementation
|
| + // may return -0.0 instead of 0.
|
| +
|
| static getYear(receiver) {
|
| return (receiver.isUtc)
|
| ? JS('int', r'(#.getUTCFullYear() + 0)', lazyAsJsDate(receiver))
|
|
|