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

Side by Side Diff: test/codegen/expect/core/core.js

Issue 959003003: Typecheck constructor initializers properly (Closed) Base URL: https://github.com/dart-lang/dev_compiler.git@master
Patch Set: Created 5 years, 9 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 unified diff | Download patch
OLDNEW
1 var core; 1 var core;
2 (function(core) { 2 (function(core) {
3 'use strict'; 3 'use strict';
4 // Function _symbolToString: (Symbol) → String 4 // Function _symbolToString: (Symbol) → String
5 function _symbolToString(symbol) { 5 function _symbolToString(symbol) {
6 return _internal.Symbol.getName(dart.as(symbol, _internal.Symbol)); 6 return _internal.Symbol.getName(dart.as(symbol, _internal.Symbol));
7 } 7 }
8 // Function _symbolMapToStringMap: (Map<Symbol, dynamic>) → dynamic 8 // Function _symbolMapToStringMap: (Map<Symbol, dynamic>) → dynamic
9 function _symbolMapToStringMap(map) { 9 function _symbolMapToStringMap(map) {
10 if (map === null) 10 if (map === null)
(...skipping 237 matching lines...) Expand 10 before | Expand all | Expand 10 after
248 subtract(duration) { 248 subtract(duration) {
249 let ms = this.millisecondsSinceEpoch; 249 let ms = this.millisecondsSinceEpoch;
250 return new DateTime.fromMillisecondsSinceEpoch(ms - duration.inMillisecond s, {isUtc: this.isUtc}); 250 return new DateTime.fromMillisecondsSinceEpoch(ms - duration.inMillisecond s, {isUtc: this.isUtc});
251 } 251 }
252 difference(other) { 252 difference(other) {
253 let ms = this.millisecondsSinceEpoch; 253 let ms = this.millisecondsSinceEpoch;
254 let otherMs = other.millisecondsSinceEpoch; 254 let otherMs = other.millisecondsSinceEpoch;
255 return new Duration({milliseconds: ms - otherMs}); 255 return new Duration({milliseconds: ms - otherMs});
256 } 256 }
257 DateTime$_internal(year, month, day, hour, minute, second, millisecond, isUt c) { 257 DateTime$_internal(year, month, day, hour, minute, second, millisecond, isUt c) {
258 this.isUtc = typeof isUtc == boolean ? isUtc : dart.throw_(new ArgumentErr or(isUtc)); 258 this.isUtc = dart.as(typeof isUtc == boolean ? isUtc : dart.throw_(new Arg umentError(isUtc)), bool);
259 this.millisecondsSinceEpoch = dart.dinvokef(/* Unimplemented unknown name */checkInt, dart.dinvoke(/* Unimplemented unknown name */Primitives, 'valueFromD ecomposedDate', year, month, day, hour, minute, second, millisecond, isUtc)); 259 this.millisecondsSinceEpoch = dart.as(dart.dinvokef(/* Unimplemented unkno wn name */checkInt, dart.dinvoke(/* Unimplemented unknown name */Primitives, 'va lueFromDecomposedDate', year, month, day, hour, minute, second, millisecond, isU tc)), int);
260 } 260 }
261 DateTime$_now() { 261 DateTime$_now() {
262 this.isUtc = false; 262 this.isUtc = false;
263 this.millisecondsSinceEpoch = dart.dinvoke(/* Unimplemented unknown name * /Primitives, 'dateNow'); 263 this.millisecondsSinceEpoch = dart.as(dart.dinvoke(/* Unimplemented unknow n name */Primitives, 'dateNow'), int);
264 } 264 }
265 static _brokenDownDateToMillisecondsSinceEpoch(year, month, day, hour, minut e, second, millisecond, isUtc) { 265 static _brokenDownDateToMillisecondsSinceEpoch(year, month, day, hour, minut e, second, millisecond, isUtc) {
266 return dart.as(dart.dinvoke(/* Unimplemented unknown name */Primitives, 'v alueFromDecomposedDate', year, month, day, hour, minute, second, millisecond, is Utc), int); 266 return dart.as(dart.dinvoke(/* Unimplemented unknown name */Primitives, 'v alueFromDecomposedDate', year, month, day, hour, minute, second, millisecond, is Utc), int);
267 } 267 }
268 get timeZoneName() { 268 get timeZoneName() {
269 if (this.isUtc) 269 if (this.isUtc)
270 return "UTC"; 270 return "UTC";
271 return dart.as(dart.dinvoke(/* Unimplemented unknown name */Primitives, 'g etTimeZoneName', this), String); 271 return dart.as(dart.dinvoke(/* Unimplemented unknown name */Primitives, 'g etTimeZoneName', this), String);
272 } 272 }
273 get timeZoneOffset() { 273 get timeZoneOffset() {
(...skipping 368 matching lines...) Expand 10 before | Expand all | Expand 10 after
642 dart.defineNamedConstructor(RangeError, 'index'); 642 dart.defineNamedConstructor(RangeError, 'index');
643 class IndexError extends ArgumentError { 643 class IndexError extends ArgumentError {
644 IndexError(invalidValue, indexable, name, message, length) { 644 IndexError(invalidValue, indexable, name, message, length) {
645 if (name === void 0) 645 if (name === void 0)
646 name = null; 646 name = null;
647 if (message === void 0) 647 if (message === void 0)
648 message = null; 648 message = null;
649 if (length === void 0) 649 if (length === void 0)
650 length = null; 650 length = null;
651 this.indexable = indexable; 651 this.indexable = indexable;
652 this.length = length !== null ? length : dart.dload(indexable, 'length'); 652 this.length = dart.as(length !== null ? length : dart.dload(indexable, 'le ngth'), int);
653 super.ArgumentError$value(invalidValue, name, message !== null ? message : "Index out of range"); 653 super.ArgumentError$value(invalidValue, name, message !== null ? message : "Index out of range");
654 } 654 }
655 get start() { 655 get start() {
656 return 0; 656 return 0;
657 } 657 }
658 get end() { 658 get end() {
659 return this.length - 1; 659 return this.length - 1;
660 } 660 }
661 toString() { 661 toString() {
662 dart.assert(this._hasValue); 662 dart.assert(this._hasValue);
(...skipping 362 matching lines...) Expand 10 before | Expand all | Expand 10 after
1025 } 1025 }
1026 dart.defineNamedConstructor(Iterable, 'generate'); 1026 dart.defineNamedConstructor(Iterable, 'generate');
1027 return Iterable; 1027 return Iterable;
1028 }); 1028 });
1029 let Iterable = Iterable$(dynamic); 1029 let Iterable = Iterable$(dynamic);
1030 let _GeneratorIterable$ = dart.generic(function(E) { 1030 let _GeneratorIterable$ = dart.generic(function(E) {
1031 class _GeneratorIterable extends collection.IterableBase$(E) { 1031 class _GeneratorIterable extends collection.IterableBase$(E) {
1032 _GeneratorIterable(_end, generator) { 1032 _GeneratorIterable(_end, generator) {
1033 this._end = _end; 1033 this._end = _end;
1034 this._start = 0; 1034 this._start = 0;
1035 this._generator = generator !== null ? generator : _id; 1035 this._generator = dart.as(generator !== null ? generator : _id, _Generat or);
1036 super.IterableBase(); 1036 super.IterableBase();
1037 } 1037 }
1038 _GeneratorIterable$slice(_start, _end, _generator) { 1038 _GeneratorIterable$slice(_start, _end, _generator) {
1039 this._start = _start; 1039 this._start = _start;
1040 this._end = _end; 1040 this._end = _end;
1041 this._generator = _generator; 1041 this._generator = _generator;
1042 super.IterableBase(); 1042 super.IterableBase();
1043 } 1043 }
1044 get iterator() { 1044 get iterator() {
1045 return new _GeneratorIterator(this._start, this._end, this._generator); 1045 return new _GeneratorIterator(this._start, this._end, this._generator);
(...skipping 1902 matching lines...) Expand 10 before | Expand all | Expand 10 after
2948 core.Stopwatch = Stopwatch; 2948 core.Stopwatch = Stopwatch;
2949 core.String = String; 2949 core.String = String;
2950 core.Runes = Runes; 2950 core.Runes = Runes;
2951 core.RuneIterator = RuneIterator; 2951 core.RuneIterator = RuneIterator;
2952 core.StringBuffer = StringBuffer; 2952 core.StringBuffer = StringBuffer;
2953 core.StringSink = StringSink; 2953 core.StringSink = StringSink;
2954 core.Symbol = Symbol; 2954 core.Symbol = Symbol;
2955 core.Type = Type; 2955 core.Type = Type;
2956 core.Uri = Uri; 2956 core.Uri = Uri;
2957 })(core || (core = {})); 2957 })(core || (core = {}));
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698