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

Side by Side Diff: lib/runtime/dart/core.js

Issue 1148333003: No dynamic at runtime (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: Created 5 years, 7 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 = dart.defineLibrary(core, {}); 1 var core = dart.defineLibrary(core, {});
2 var _js_helper = dart.lazyImport(_js_helper); 2 var _js_helper = dart.lazyImport(_js_helper);
3 var _internal = dart.lazyImport(_internal); 3 var _internal = dart.lazyImport(_internal);
4 var collection = dart.lazyImport(collection); 4 var collection = dart.lazyImport(collection);
5 var _interceptors = dart.lazyImport(_interceptors); 5 var _interceptors = dart.lazyImport(_interceptors);
6 var math = dart.lazyImport(math); 6 var math = dart.lazyImport(math);
7 var convert = dart.lazyImport(convert); 7 var convert = dart.lazyImport(convert);
8 (function(exports, _js_helper, _internal, collection, _interceptors, math, conve rt) { 8 (function(exports, _js_helper, _internal, collection, _interceptors, math, conve rt) {
9 'use strict'; 9 'use strict';
10 class Object { 10 class Object {
(...skipping 16 matching lines...) Expand all
27 } 27 }
28 noSuchMethod(invocation) { 28 noSuchMethod(invocation) {
29 throw new NoSuchMethodError(this, invocation.memberName, invocation.positi onalArguments, invocation.namedArguments); 29 throw new NoSuchMethodError(this, invocation.memberName, invocation.positi onalArguments, invocation.namedArguments);
30 } 30 }
31 get runtimeType() { 31 get runtimeType() {
32 return dart.realRuntimeType(this); 32 return dart.realRuntimeType(this);
33 } 33 }
34 } 34 }
35 dart.setSignature(Object, { 35 dart.setSignature(Object, {
36 methods: () => ({ 36 methods: () => ({
37 '==': dart.functionType(bool, [dart.dynamic]), 37 '==': dart.functionType(bool, [Object]),
38 toString: dart.functionType(String, []), 38 toString: dart.functionType(String, []),
39 noSuchMethod: dart.functionType(dart.dynamic, [Invocation]) 39 noSuchMethod: dart.functionType(Object, [Invocation])
40 }) 40 })
41 }); 41 });
42 class JsName extends Object { 42 class JsName extends Object {
43 JsName(opts) { 43 JsName(opts) {
44 let name = opts && 'name' in opts ? opts.name : null; 44 let name = opts && 'name' in opts ? opts.name : null;
45 this.name = name; 45 this.name = name;
46 } 46 }
47 } 47 }
48 class JsPeerInterface extends Object { 48 class JsPeerInterface extends Object {
49 JsPeerInterface(opts) { 49 JsPeerInterface(opts) {
(...skipping 729 matching lines...) Expand 10 before | Expand all | Expand 10 after
779 } 779 }
780 return `RangeError: ${this.message} (${value})${explanation}`; 780 return `RangeError: ${this.message} (${value})${explanation}`;
781 } 781 }
782 } 782 }
783 dart.defineNamedConstructor(RangeError, 'value'); 783 dart.defineNamedConstructor(RangeError, 'value');
784 dart.defineNamedConstructor(RangeError, 'range'); 784 dart.defineNamedConstructor(RangeError, 'range');
785 dart.defineNamedConstructor(RangeError, 'index'); 785 dart.defineNamedConstructor(RangeError, 'index');
786 dart.setSignature(RangeError, { 786 dart.setSignature(RangeError, {
787 statics: () => ({ 787 statics: () => ({
788 checkValueInInterval: dart.functionType(dart.void, [int, int, int], [Strin g, String]), 788 checkValueInInterval: dart.functionType(dart.void, [int, int, int], [Strin g, String]),
789 checkValidIndex: dart.functionType(dart.void, [int, dart.dynamic], [String , int, String]), 789 checkValidIndex: dart.functionType(dart.void, [int, Object], [String, int, String]),
790 checkValidRange: dart.functionType(dart.void, [int, int, int], [String, St ring, String]), 790 checkValidRange: dart.functionType(dart.void, [int, int, int], [String, St ring, String]),
791 checkNotNegative: dart.functionType(dart.void, [int], [String, String]) 791 checkNotNegative: dart.functionType(dart.void, [int], [String, String])
792 }), 792 }),
793 names: ['checkValueInInterval', 'checkValidIndex', 'checkValidRange', 'check NotNegative'] 793 names: ['checkValueInInterval', 'checkValidIndex', 'checkValidRange', 'check NotNegative']
794 }); 794 });
795 class IndexError extends ArgumentError { 795 class IndexError extends ArgumentError {
796 IndexError(invalidValue, indexable, name, message, length) { 796 IndexError(invalidValue, indexable, name, message, length) {
797 if (name === void 0) 797 if (name === void 0)
798 name = null; 798 name = null;
799 if (message === void 0) 799 if (message === void 0)
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
867 } 867 }
868 if (this[_namedArguments] != null) { 868 if (this[_namedArguments] != null) {
869 this[_namedArguments].forEach(dart.fn((key, value) => { 869 this[_namedArguments].forEach(dart.fn((key, value) => {
870 if (dart.notNull(i) > 0) { 870 if (dart.notNull(i) > 0) {
871 sb.write(", "); 871 sb.write(", ");
872 } 872 }
873 sb.write(_symbolToString(key)); 873 sb.write(_symbolToString(key));
874 sb.write(": "); 874 sb.write(": ");
875 sb.write(Error.safeToString(value)); 875 sb.write(Error.safeToString(value));
876 i = dart.notNull(i) + 1; 876 i = dart.notNull(i) + 1;
877 }, dart.dynamic, [Symbol, dart.dynamic])); 877 }, Object, [Symbol, Object]));
878 } 878 }
879 if (this[_existingArgumentNames] == null) { 879 if (this[_existingArgumentNames] == null) {
880 return `NoSuchMethodError : method not found: '${this[_memberName]}'\n` + `Receiver: ${Error.safeToString(this[_receiver])}\n` + `Arguments: [${sb}]`; 880 return `NoSuchMethodError : method not found: '${this[_memberName]}'\n` + `Receiver: ${Error.safeToString(this[_receiver])}\n` + `Arguments: [${sb}]`;
881 } else { 881 } else {
882 let actualParameters = dart.toString(sb); 882 let actualParameters = dart.toString(sb);
883 sb = new StringBuffer(); 883 sb = new StringBuffer();
884 for (let i = 0; dart.notNull(i) < dart.notNull(this[_existingArgumentNam es][$length]); i = dart.notNull(i) + 1) { 884 for (let i = 0; dart.notNull(i) < dart.notNull(this[_existingArgumentNam es][$length]); i = dart.notNull(i) + 1) {
885 if (dart.notNull(i) > 0) { 885 if (dart.notNull(i) > 0) {
886 sb.write(", "); 886 sb.write(", ");
887 } 887 }
(...skipping 257 matching lines...) Expand 10 before | Expand all | Expand 10 after
1145 static _toMangledNames(namedArguments) { 1145 static _toMangledNames(namedArguments) {
1146 let result = dart.map(); 1146 let result = dart.map();
1147 namedArguments.forEach(dart.fn((symbol, value) => { 1147 namedArguments.forEach(dart.fn((symbol, value) => {
1148 result.set(_symbolToString(dart.as(symbol, Symbol)), value); 1148 result.set(_symbolToString(dart.as(symbol, Symbol)), value);
1149 })); 1149 }));
1150 return result; 1150 return result;
1151 } 1151 }
1152 } 1152 }
1153 dart.setSignature(Function, { 1153 dart.setSignature(Function, {
1154 statics: () => ({ 1154 statics: () => ({
1155 apply: dart.functionType(dart.dynamic, [Function, List], [Map$(Symbol, dar t.dynamic)]), 1155 apply: dart.functionType(Object, [Function, List], [Map$(Symbol, Object)]) ,
1156 _toMangledNames: dart.functionType(Map$(String, dart.dynamic), [Map$(Symbo l, dart.dynamic)]) 1156 _toMangledNames: dart.functionType(Map$(String, Object), [Map$(Symbol, Obj ect)])
1157 }), 1157 }),
1158 names: ['apply', '_toMangledNames'] 1158 names: ['apply', '_toMangledNames']
1159 }); 1159 });
1160 function identical(a, b) { 1160 function identical(a, b) {
1161 return _js_helper.Primitives.identicalImplementation(a, b); 1161 return _js_helper.Primitives.identicalImplementation(a, b);
1162 } 1162 }
1163 dart.fn(identical, bool, [Object, Object]); 1163 dart.fn(identical, bool, [Object, Object]);
1164 function identityHashCode(object) { 1164 function identityHashCode(object) {
1165 return _js_helper.objectHashCode(object); 1165 return _js_helper.objectHashCode(object);
1166 } 1166 }
(...skipping 272 matching lines...) Expand 10 before | Expand all | Expand 10 after
1439 dart.as(f, dart.functionType(dart.void, [E])); 1439 dart.as(f, dart.functionType(dart.void, [E]));
1440 let length = this[$length]; 1440 let length = this[$length];
1441 for (let i = 0; dart.notNull(i) < dart.notNull(length); i = dart.notNull (i) + 1) { 1441 for (let i = 0; dart.notNull(i) < dart.notNull(length); i = dart.notNull (i) + 1) {
1442 f(dart.as(this[i], E)); 1442 f(dart.as(this[i], E));
1443 if (length != this[$length]) { 1443 if (length != this[$length]) {
1444 throw new ConcurrentModificationError(this); 1444 throw new ConcurrentModificationError(this);
1445 } 1445 }
1446 } 1446 }
1447 } 1447 }
1448 [$map](f) { 1448 [$map](f) {
1449 dart.as(f, dart.functionType(dart.dynamic, [E])); 1449 dart.as(f, dart.functionType(Object, [E]));
1450 return _internal.IterableMixinWorkaround.mapList(this, f); 1450 return _internal.IterableMixinWorkaround.mapList(this, f);
1451 } 1451 }
1452 [$join](separator) { 1452 [$join](separator) {
1453 if (separator === void 0) 1453 if (separator === void 0)
1454 separator = ""; 1454 separator = "";
1455 let list = new (List$())(this[$length]); 1455 let list = new (List$())(this[$length]);
1456 for (let i = 0; dart.notNull(i) < dart.notNull(this[$length]); i = dart. notNull(i) + 1) { 1456 for (let i = 0; dart.notNull(i) < dart.notNull(this[$length]); i = dart. notNull(i) + 1) {
1457 list[$set](i, `${this[$get](i)}`); 1457 list[$set](i, `${this[$get](i)}`);
1458 } 1458 }
1459 return list.join(separator); 1459 return list.join(separator);
(...skipping 10 matching lines...) Expand all
1470 } 1470 }
1471 [$skipWhile](test) { 1471 [$skipWhile](test) {
1472 dart.as(test, dart.functionType(bool, [E])); 1472 dart.as(test, dart.functionType(bool, [E]));
1473 return new (_internal.IterableMixinWorkaround$(E))().skipWhile(this, tes t); 1473 return new (_internal.IterableMixinWorkaround$(E))().skipWhile(this, tes t);
1474 } 1474 }
1475 [$reduce](combine) { 1475 [$reduce](combine) {
1476 dart.as(combine, dart.functionType(E, [E, E])); 1476 dart.as(combine, dart.functionType(E, [E, E]));
1477 return dart.as(_internal.IterableMixinWorkaround.reduce(this, combine), E); 1477 return dart.as(_internal.IterableMixinWorkaround.reduce(this, combine), E);
1478 } 1478 }
1479 [$fold](initialValue, combine) { 1479 [$fold](initialValue, combine) {
1480 dart.as(combine, dart.functionType(dart.dynamic, [dart.dynamic, E])); 1480 dart.as(combine, dart.functionType(Object, [dart.bottom, E]));
1481 return _internal.IterableMixinWorkaround.fold(this, initialValue, combin e); 1481 return _internal.IterableMixinWorkaround.fold(this, initialValue, combin e);
1482 } 1482 }
1483 [$firstWhere](test, opts) { 1483 [$firstWhere](test, opts) {
1484 dart.as(test, dart.functionType(bool, [E])); 1484 dart.as(test, dart.functionType(bool, [E]));
1485 let orElse = opts && 'orElse' in opts ? opts.orElse : null; 1485 let orElse = opts && 'orElse' in opts ? opts.orElse : null;
1486 dart.as(orElse, dart.functionType(E, [])); 1486 dart.as(orElse, dart.functionType(E, []));
1487 return dart.as(_internal.IterableMixinWorkaround.firstWhere(this, test, orElse), E); 1487 return dart.as(_internal.IterableMixinWorkaround.firstWhere(this, test, orElse), E);
1488 } 1488 }
1489 [$lastWhere](test, opts) { 1489 [$lastWhere](test, opts) {
1490 dart.as(test, dart.functionType(bool, [E])); 1490 dart.as(test, dart.functionType(bool, [E]));
(...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after
1734 return new (_internal.IterableMixinWorkaround$(E))().asMapList(this); 1734 return new (_internal.IterableMixinWorkaround$(E))().asMapList(this);
1735 } 1735 }
1736 } 1736 }
1737 dart.setBaseClass(List, dart.global.Array); 1737 dart.setBaseClass(List, dart.global.Array);
1738 List[dart.implements] = () => [Iterable$(E), _internal.EfficientLength]; 1738 List[dart.implements] = () => [Iterable$(E), _internal.EfficientLength];
1739 dart.defineNamedConstructor(List, 'filled'); 1739 dart.defineNamedConstructor(List, 'filled');
1740 dart.defineNamedConstructor(List, 'from'); 1740 dart.defineNamedConstructor(List, 'from');
1741 dart.defineNamedConstructor(List, 'generate'); 1741 dart.defineNamedConstructor(List, 'generate');
1742 dart.setSignature(List, { 1742 dart.setSignature(List, {
1743 methods: () => ({ 1743 methods: () => ({
1744 [$checkMutable]: dart.functionType(dart.dynamic, [dart.dynamic]), 1744 [$checkMutable]: dart.functionType(Object, [Object]),
1745 [$checkGrowable]: dart.functionType(dart.dynamic, [dart.dynamic]), 1745 [$checkGrowable]: dart.functionType(Object, [Object]),
1746 [$where]: dart.functionType(Iterable$(E), [dart.functionType(bool, [E])] ), 1746 [$where]: dart.functionType(Iterable$(E), [dart.functionType(bool, [E])] ),
1747 [$expand]: dart.functionType(Iterable, [dart.functionType(Iterable, [E]) ]), 1747 [$expand]: dart.functionType(Iterable, [dart.functionType(Iterable, [E]) ]),
1748 [$forEach]: dart.functionType(dart.void, [dart.functionType(dart.void, [ E])]), 1748 [$forEach]: dart.functionType(dart.void, [dart.functionType(dart.void, [ E])]),
1749 [$map]: dart.functionType(Iterable, [dart.functionType(dart.dynamic, [E] )]), 1749 [$map]: dart.functionType(Iterable, [dart.functionType(Object, [E])]),
1750 [$join]: dart.functionType(String, [], [String]), 1750 [$join]: dart.functionType(String, [], [String]),
1751 [$take]: dart.functionType(Iterable$(E), [int]), 1751 [$take]: dart.functionType(Iterable$(E), [int]),
1752 [$takeWhile]: dart.functionType(Iterable$(E), [dart.functionType(bool, [ E])]), 1752 [$takeWhile]: dart.functionType(Iterable$(E), [dart.functionType(bool, [ E])]),
1753 [$skip]: dart.functionType(Iterable$(E), [int]), 1753 [$skip]: dart.functionType(Iterable$(E), [int]),
1754 [$skipWhile]: dart.functionType(Iterable$(E), [dart.functionType(bool, [ E])]), 1754 [$skipWhile]: dart.functionType(Iterable$(E), [dart.functionType(bool, [ E])]),
1755 [$reduce]: dart.functionType(E, [dart.functionType(E, [E, E])]), 1755 [$reduce]: dart.functionType(E, [dart.functionType(E, [E, E])]),
1756 [$fold]: dart.functionType(dart.dynamic, [dart.dynamic, dart.functionTyp e(dart.dynamic, [dart.dynamic, E])]), 1756 [$fold]: dart.functionType(Object, [Object, dart.functionType(Object, [d art.bottom, E])]),
1757 [$firstWhere]: dart.functionType(E, [dart.functionType(bool, [E])], {rEl s: dart.functionType(E, [])}), 1757 [$firstWhere]: dart.functionType(E, [dart.functionType(bool, [E])], {rEl s: dart.functionType(E, [])}),
1758 [$lastWhere]: dart.functionType(E, [dart.functionType(bool, [E])], {rEls : dart.functionType(E, [])}), 1758 [$lastWhere]: dart.functionType(E, [dart.functionType(bool, [E])], {rEls : dart.functionType(E, [])}),
1759 [$singleWhere]: dart.functionType(E, [dart.functionType(bool, [E])]), 1759 [$singleWhere]: dart.functionType(E, [dart.functionType(bool, [E])]),
1760 [$elementAt]: dart.functionType(E, [int]), 1760 [$elementAt]: dart.functionType(E, [int]),
1761 [$any]: dart.functionType(bool, [dart.functionType(bool, [E])]), 1761 [$any]: dart.functionType(bool, [dart.functionType(bool, [E])]),
1762 [$every]: dart.functionType(bool, [dart.functionType(bool, [E])]), 1762 [$every]: dart.functionType(bool, [dart.functionType(bool, [E])]),
1763 [$contains]: dart.functionType(bool, [Object]), 1763 [$contains]: dart.functionType(bool, [Object]),
1764 [$toList]: dart.functionType(List$(E), [], {rowabl: bool}), 1764 [$toList]: dart.functionType(List$(E), [], {rowabl: bool}),
1765 [$toSet]: dart.functionType(exports.Set$(E), []), 1765 [$toSet]: dart.functionType(exports.Set$(E), []),
1766 [$get]: dart.functionType(E, [int]), 1766 [$get]: dart.functionType(E, [int]),
(...skipping 444 matching lines...) Expand 10 before | Expand all | Expand 10 after
2211 } 2211 }
2212 } 2212 }
2213 StringBuffer[dart.implements] = () => [StringSink]; 2213 StringBuffer[dart.implements] = () => [StringSink];
2214 dart.setSignature(StringBuffer, { 2214 dart.setSignature(StringBuffer, {
2215 methods: () => ({ 2215 methods: () => ({
2216 write: dart.functionType(dart.void, [Object]), 2216 write: dart.functionType(dart.void, [Object]),
2217 writeCharCode: dart.functionType(dart.void, [int]), 2217 writeCharCode: dart.functionType(dart.void, [int]),
2218 writeAll: dart.functionType(dart.void, [Iterable], [String]), 2218 writeAll: dart.functionType(dart.void, [Iterable], [String]),
2219 writeln: dart.functionType(dart.void, [], [Object]), 2219 writeln: dart.functionType(dart.void, [], [Object]),
2220 clear: dart.functionType(dart.void, []), 2220 clear: dart.functionType(dart.void, []),
2221 [_writeString]: dart.functionType(dart.void, [dart.dynamic]) 2221 [_writeString]: dart.functionType(dart.void, [Object])
2222 }) 2222 })
2223 }); 2223 });
2224 class StringSink extends Object {} 2224 class StringSink extends Object {}
2225 class Symbol extends Object { 2225 class Symbol extends Object {
2226 Symbol(name) { 2226 Symbol(name) {
2227 return new _internal.Symbol(name); 2227 return new _internal.Symbol(name);
2228 } 2228 }
2229 } 2229 }
2230 class Type extends Object {} 2230 class Type extends Object {}
2231 let _writeAuthority = dart.JsSymbol('_writeAuthority'); 2231 let _writeAuthority = dart.JsSymbol('_writeAuthority');
(...skipping 611 matching lines...) Expand 10 before | Expand all | Expand 10 after
2843 static _makePath(path, start, end, pathSegments, ensureLeadingSlash, isFile) { 2843 static _makePath(path, start, end, pathSegments, ensureLeadingSlash, isFile) {
2844 if (path == null && dart.notNull(pathSegments == null)) 2844 if (path == null && dart.notNull(pathSegments == null))
2845 return isFile ? "/" : ""; 2845 return isFile ? "/" : "";
2846 if (path != null && dart.notNull(pathSegments != null)) { 2846 if (path != null && dart.notNull(pathSegments != null)) {
2847 throw new ArgumentError('Both path and pathSegments specified'); 2847 throw new ArgumentError('Both path and pathSegments specified');
2848 } 2848 }
2849 let result = null; 2849 let result = null;
2850 if (path != null) { 2850 if (path != null) {
2851 result = Uri._normalize(path, start, end, dart.as(Uri._pathCharOrSlashTa ble, List$(int))); 2851 result = Uri._normalize(path, start, end, dart.as(Uri._pathCharOrSlashTa ble, List$(int)));
2852 } else { 2852 } else {
2853 result = pathSegments[$map](dart.fn(s => Uri._uriEncode(dart.as(Uri._pat hCharTable, List$(int)), dart.as(s, String)), String, [dart.dynamic]))[$join]("/ "); 2853 result = pathSegments[$map](dart.fn(s => Uri._uriEncode(dart.as(Uri._pat hCharTable, List$(int)), dart.as(s, String)), String, [Object]))[$join]("/");
2854 } 2854 }
2855 if (dart.dload(result, 'isEmpty')) { 2855 if (dart.dload(result, 'isEmpty')) {
2856 if (isFile) 2856 if (isFile)
2857 return "/"; 2857 return "/";
2858 } else if ((dart.notNull(isFile) || dart.notNull(ensureLeadingSlash)) && d art.notNull(!dart.equals(dart.dsend(result, 'codeUnitAt', 0), Uri._SLASH))) { 2858 } else if ((dart.notNull(isFile) || dart.notNull(ensureLeadingSlash)) && d art.notNull(!dart.equals(dart.dsend(result, 'codeUnitAt', 0), Uri._SLASH))) {
2859 return `/${result}`; 2859 return `/${result}`;
2860 } 2860 }
2861 return dart.as(result, String); 2861 return dart.as(result, String);
2862 } 2862 }
2863 static _makeQuery(query, start, end, queryParameters) { 2863 static _makeQuery(query, start, end, queryParameters) {
(...skipping 377 matching lines...) Expand 10 before | Expand all | Expand 10 after
3241 ['=='](other) { 3241 ['=='](other) {
3242 if (!dart.is(other, Uri)) 3242 if (!dart.is(other, Uri))
3243 return false; 3243 return false;
3244 let uri = dart.as(other, Uri); 3244 let uri = dart.as(other, Uri);
3245 return this.scheme == uri.scheme && this.hasAuthority == uri.hasAuthority && this.userInfo == uri.userInfo && this.host == uri.host && this.port == uri.po rt && this.path == uri.path && this.hasQuery == uri.hasQuery && this.query == ur i.query && this.hasFragment == uri.hasFragment && this.fragment == uri.fragment; 3245 return this.scheme == uri.scheme && this.hasAuthority == uri.hasAuthority && this.userInfo == uri.userInfo && this.host == uri.host && this.port == uri.po rt && this.path == uri.path && this.hasQuery == uri.hasQuery && this.query == ur i.query && this.hasFragment == uri.hasFragment && this.fragment == uri.fragment;
3246 } 3246 }
3247 get hashCode() { 3247 get hashCode() {
3248 let combine = (part, current) => { 3248 let combine = (part, current) => {
3249 return dart.as(dart.dsend(dart.dsend(dart.dsend(current, '*', 31), '+', dart.hashCode(part)), '&', 1073741823), int); 3249 return dart.as(dart.dsend(dart.dsend(dart.dsend(current, '*', 31), '+', dart.hashCode(part)), '&', 1073741823), int);
3250 }; 3250 };
3251 dart.fn(combine, int, [dart.dynamic, dart.dynamic]); 3251 dart.fn(combine, int, [Object, Object]);
3252 return combine(this.scheme, combine(this.userInfo, combine(this.host, comb ine(this.port, combine(this.path, combine(this.query, combine(this.fragment, 1)) ))))); 3252 return combine(this.scheme, combine(this.userInfo, combine(this.host, comb ine(this.port, combine(this.path, combine(this.query, combine(this.fragment, 1)) )))));
3253 } 3253 }
3254 static _addIfNonEmpty(sb, test, first, second) { 3254 static _addIfNonEmpty(sb, test, first, second) {
3255 if ("" != test) { 3255 if ("" != test) {
3256 sb.write(first); 3256 sb.write(first);
3257 sb.write(second); 3257 sb.write(second);
3258 } 3258 }
3259 } 3259 }
3260 static encodeComponent(component) { 3260 static encodeComponent(component) {
3261 return Uri._uriEncode(dart.as(Uri._unreserved2396Table, List$(int)), compo nent); 3261 return Uri._uriEncode(dart.as(Uri._unreserved2396Table, List$(int)), compo nent);
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
3315 start = 0; 3315 start = 0;
3316 if (end === void 0) 3316 if (end === void 0)
3317 end = null; 3317 end = null;
3318 if (end == null) 3318 if (end == null)
3319 end = host.length; 3319 end = host.length;
3320 let error = (msg, position) => { 3320 let error = (msg, position) => {
3321 if (position === void 0) 3321 if (position === void 0)
3322 position = null; 3322 position = null;
3323 throw new FormatException(`Illegal IPv6 address, ${msg}`, host, dart.as( position, int)); 3323 throw new FormatException(`Illegal IPv6 address, ${msg}`, host, dart.as( position, int));
3324 }; 3324 };
3325 dart.fn(error, dart.void, [String], [dart.dynamic]); 3325 dart.fn(error, dart.void, [String], [Object]);
3326 let parseHex = (start, end) => { 3326 let parseHex = (start, end) => {
3327 if (dart.notNull(end) - dart.notNull(start) > 4) { 3327 if (dart.notNull(end) - dart.notNull(start) > 4) {
3328 error('an IPv6 part can only contain a maximum of 4 hex digits', start ); 3328 error('an IPv6 part can only contain a maximum of 4 hex digits', start );
3329 } 3329 }
3330 let value = int.parse(host.substring(start, end), {radix: 16}); 3330 let value = int.parse(host.substring(start, end), {radix: 16});
3331 if (dart.notNull(value) < 0 || dart.notNull(value) > (1 << 16) - 1) { 3331 if (dart.notNull(value) < 0 || dart.notNull(value) > (1 << 16) - 1) {
3332 error('each part must be in the range of `0x0..0xFFFF`', start); 3332 error('each part must be in the range of `0x0..0xFFFF`', start);
3333 } 3333 }
3334 return value; 3334 return value;
3335 }; 3335 };
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after
3504 toFilePath: dart.functionType(String, [], {indow: bool}), 3504 toFilePath: dart.functionType(String, [], {indow: bool}),
3505 [_toFilePath]: dart.functionType(String, []), 3505 [_toFilePath]: dart.functionType(String, []),
3506 [_toWindowsFilePath]: dart.functionType(String, []), 3506 [_toWindowsFilePath]: dart.functionType(String, []),
3507 [_writeAuthority]: dart.functionType(dart.void, [StringSink]) 3507 [_writeAuthority]: dart.functionType(dart.void, [StringSink])
3508 }), 3508 }),
3509 statics: () => ({ 3509 statics: () => ({
3510 _defaultPort: dart.functionType(int, [String]), 3510 _defaultPort: dart.functionType(int, [String]),
3511 parse: dart.functionType(Uri, [String]), 3511 parse: dart.functionType(Uri, [String]),
3512 _fail: dart.functionType(dart.void, [String, int, String]), 3512 _fail: dart.functionType(dart.void, [String, int, String]),
3513 _makeHttpUri: dart.functionType(Uri, [String, String, String, Map$(String, String)]), 3513 _makeHttpUri: dart.functionType(Uri, [String, String, String, Map$(String, String)]),
3514 _checkNonWindowsPathReservedCharacters: dart.functionType(dart.dynamic, [L ist$(String), bool]), 3514 _checkNonWindowsPathReservedCharacters: dart.functionType(Object, [List$(S tring), bool]),
3515 _checkWindowsPathReservedCharacters: dart.functionType(dart.dynamic, [List $(String), bool], [int]), 3515 _checkWindowsPathReservedCharacters: dart.functionType(Object, [List$(Stri ng), bool], [int]),
3516 _checkWindowsDriveLetter: dart.functionType(dart.dynamic, [int, bool]), 3516 _checkWindowsDriveLetter: dart.functionType(Object, [int, bool]),
3517 _makeFileUri: dart.functionType(dart.dynamic, [String]), 3517 _makeFileUri: dart.functionType(Object, [String]),
3518 _makeWindowsFileUrl: dart.functionType(dart.dynamic, [String]), 3518 _makeWindowsFileUrl: dart.functionType(Object, [String]),
3519 _makePort: dart.functionType(int, [int, String]), 3519 _makePort: dart.functionType(int, [int, String]),
3520 _makeHost: dart.functionType(String, [String, int, int, bool]), 3520 _makeHost: dart.functionType(String, [String, int, int, bool]),
3521 _isRegNameChar: dart.functionType(bool, [int]), 3521 _isRegNameChar: dart.functionType(bool, [int]),
3522 _normalizeRegName: dart.functionType(String, [String, int, int]), 3522 _normalizeRegName: dart.functionType(String, [String, int, int]),
3523 _makeScheme: dart.functionType(String, [String, int]), 3523 _makeScheme: dart.functionType(String, [String, int]),
3524 _makeUserInfo: dart.functionType(String, [String, int, int]), 3524 _makeUserInfo: dart.functionType(String, [String, int, int]),
3525 _makePath: dart.functionType(String, [String, int, int, Iterable$(String), bool, bool]), 3525 _makePath: dart.functionType(String, [String, int, int, Iterable$(String), bool, bool]),
3526 _makeQuery: dart.functionType(String, [String, int, int, Map$(String, Stri ng)]), 3526 _makeQuery: dart.functionType(String, [String, int, int, Map$(String, Stri ng)]),
3527 _makeFragment: dart.functionType(String, [String, int, int]), 3527 _makeFragment: dart.functionType(String, [String, int, int]),
3528 _stringOrNullLength: dart.functionType(int, [String]), 3528 _stringOrNullLength: dart.functionType(int, [String]),
3529 _isHexDigit: dart.functionType(bool, [int]), 3529 _isHexDigit: dart.functionType(bool, [int]),
3530 _hexValue: dart.functionType(int, [int]), 3530 _hexValue: dart.functionType(int, [int]),
3531 _normalizeEscape: dart.functionType(String, [String, int, bool]), 3531 _normalizeEscape: dart.functionType(String, [String, int, bool]),
3532 _isUnreservedChar: dart.functionType(bool, [int]), 3532 _isUnreservedChar: dart.functionType(bool, [int]),
3533 _escapeChar: dart.functionType(String, [dart.dynamic]), 3533 _escapeChar: dart.functionType(String, [Object]),
3534 _normalize: dart.functionType(String, [String, int, int, List$(int)]), 3534 _normalize: dart.functionType(String, [String, int, int, List$(int)]),
3535 _isSchemeCharacter: dart.functionType(bool, [int]), 3535 _isSchemeCharacter: dart.functionType(bool, [int]),
3536 _isGeneralDelimiter: dart.functionType(bool, [int]), 3536 _isGeneralDelimiter: dart.functionType(bool, [int]),
3537 _addIfNonEmpty: dart.functionType(dart.void, [StringBuffer, String, String , String]), 3537 _addIfNonEmpty: dart.functionType(dart.void, [StringBuffer, String, String , String]),
3538 encodeComponent: dart.functionType(String, [String]), 3538 encodeComponent: dart.functionType(String, [String]),
3539 encodeQueryComponent: dart.functionType(String, [String], {ncodin: convert .Encoding}), 3539 encodeQueryComponent: dart.functionType(String, [String], {ncodin: convert .Encoding}),
3540 decodeComponent: dart.functionType(String, [String]), 3540 decodeComponent: dart.functionType(String, [String]),
3541 decodeQueryComponent: dart.functionType(String, [String], {ncodin: convert .Encoding}), 3541 decodeQueryComponent: dart.functionType(String, [String], {ncodin: convert .Encoding}),
3542 encodeFull: dart.functionType(String, [String]), 3542 encodeFull: dart.functionType(String, [String]),
3543 decodeFull: dart.functionType(String, [String]), 3543 decodeFull: dart.functionType(String, [String]),
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
3588 Uri._pathCharTable = dart.const([0, 0, 32722, 12287, 65535, 34815, 65534, 1843 1]); 3588 Uri._pathCharTable = dart.const([0, 0, 32722, 12287, 65535, 34815, 65534, 1843 1]);
3589 Uri._pathCharOrSlashTable = dart.const([0, 0, 65490, 12287, 65535, 34815, 6553 4, 18431]); 3589 Uri._pathCharOrSlashTable = dart.const([0, 0, 65490, 12287, 65535, 34815, 6553 4, 18431]);
3590 Uri._queryCharTable = dart.const([0, 0, 65490, 45055, 65535, 34815, 65534, 184 31]); 3590 Uri._queryCharTable = dart.const([0, 0, 65490, 45055, 65535, 34815, 65534, 184 31]);
3591 function _symbolToString(symbol) { 3591 function _symbolToString(symbol) {
3592 return _internal.Symbol.getName(dart.as(symbol, _internal.Symbol)); 3592 return _internal.Symbol.getName(dart.as(symbol, _internal.Symbol));
3593 } 3593 }
3594 dart.fn(_symbolToString, String, [Symbol]); 3594 dart.fn(_symbolToString, String, [Symbol]);
3595 function _symbolMapToStringMap(map) { 3595 function _symbolMapToStringMap(map) {
3596 if (map == null) 3596 if (map == null)
3597 return null; 3597 return null;
3598 let result = new (Map$(String, dart.dynamic))(); 3598 let result = new (Map$(String, Object))();
3599 map.forEach(dart.fn((key, value) => { 3599 map.forEach(dart.fn((key, value) => {
3600 result.set(_symbolToString(key), value); 3600 result.set(_symbolToString(key), value);
3601 }, dart.dynamic, [Symbol, dart.dynamic])); 3601 }, Object, [Symbol, Object]));
3602 return result; 3602 return result;
3603 } 3603 }
3604 dart.fn(_symbolMapToStringMap, dart.dynamic, [Map$(Symbol, dart.dynamic)]); 3604 dart.fn(_symbolMapToStringMap, Object, [Map$(Symbol, Object)]);
3605 class SupportJsExtensionMethods extends Object { 3605 class SupportJsExtensionMethods extends Object {
3606 SupportJsExtensionMethods() { 3606 SupportJsExtensionMethods() {
3607 } 3607 }
3608 } 3608 }
3609 class _ListConstructorSentinel extends Object { 3609 class _ListConstructorSentinel extends Object {
3610 _ListConstructorSentinel() { 3610 _ListConstructorSentinel() {
3611 } 3611 }
3612 } 3612 }
3613 // Exports: 3613 // Exports:
3614 exports.Object = Object; 3614 exports.Object = Object;
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
3734 exports.Stopwatch = Stopwatch; 3734 exports.Stopwatch = Stopwatch;
3735 exports.String = String; 3735 exports.String = String;
3736 exports.RuneIterator = RuneIterator; 3736 exports.RuneIterator = RuneIterator;
3737 exports.StringBuffer = StringBuffer; 3737 exports.StringBuffer = StringBuffer;
3738 exports.StringSink = StringSink; 3738 exports.StringSink = StringSink;
3739 exports.Symbol = Symbol; 3739 exports.Symbol = Symbol;
3740 exports.Type = Type; 3740 exports.Type = Type;
3741 exports.Uri = Uri; 3741 exports.Uri = Uri;
3742 exports.SupportJsExtensionMethods = SupportJsExtensionMethods; 3742 exports.SupportJsExtensionMethods = SupportJsExtensionMethods;
3743 })(core, _js_helper, _internal, collection, _interceptors, math, convert); 3743 })(core, _js_helper, _internal, collection, _interceptors, math, convert);
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698