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

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

Issue 1122313002: Typing fixes to eliminate casts/dcalls (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: Rebase 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
« no previous file with comments | « lib/runtime/dart/collection.js ('k') | lib/runtime/dart/core.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 var convert; 1 var convert;
2 (function(exports) { 2 (function(exports) {
3 'use strict'; 3 'use strict';
4 let ASCII = dart.const(new AsciiCodec()); 4 let ASCII = dart.const(new AsciiCodec());
5 let _ASCII_MASK = 127; 5 let _ASCII_MASK = 127;
6 let _allowInvalid = Symbol('_allowInvalid'); 6 let _allowInvalid = Symbol('_allowInvalid');
7 let Codec$ = dart.generic(function(S, T) { 7 let Codec$ = dart.generic(function(S, T) {
8 class Codec extends core.Object { 8 class Codec extends core.Object {
9 Codec() { 9 Codec() {
10 } 10 }
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
84 fuse(other) { 84 fuse(other) {
85 dart.as(other, Converter$(T, dart.dynamic)); 85 dart.as(other, Converter$(T, dart.dynamic));
86 return new (_FusedConverter$(S, T, dart.dynamic))(this, other); 86 return new (_FusedConverter$(S, T, dart.dynamic))(this, other);
87 } 87 }
88 startChunkedConversion(sink) { 88 startChunkedConversion(sink) {
89 dart.as(sink, core.Sink$(T)); 89 dart.as(sink, core.Sink$(T));
90 throw new core.UnsupportedError(`This converter does not support chunked conversions: ${this}`); 90 throw new core.UnsupportedError(`This converter does not support chunked conversions: ${this}`);
91 } 91 }
92 bind(source) { 92 bind(source) {
93 dart.as(source, async.Stream$(S)); 93 dart.as(source, async.Stream$(S));
94 return new async.Stream$(T).eventTransformed(source, (sink => new _Conve rterStreamEventSink(this, sink)).bind(this)); 94 return new (async.Stream$(T)).eventTransformed(source, (sink => new _Con verterStreamEventSink(this, sink)).bind(this));
95 } 95 }
96 } 96 }
97 Converter[dart.implements] = () => [async.StreamTransformer$(S, T)]; 97 Converter[dart.implements] = () => [async.StreamTransformer$(S, T)];
98 return Converter; 98 return Converter;
99 }); 99 });
100 let Converter = Converter$(); 100 let Converter = Converter$();
101 class _UnicodeSubsetEncoder extends Converter$(core.String, core.List$(core.in t)) { 101 class _UnicodeSubsetEncoder extends Converter$(core.String, core.List$(core.in t)) {
102 _UnicodeSubsetEncoder(subsetMask) { 102 _UnicodeSubsetEncoder(subsetMask) {
103 this[_subsetMask] = subsetMask; 103 this[_subsetMask] = subsetMask;
104 super.Converter(); 104 super.Converter();
(...skipping 2318 matching lines...) Expand 10 before | Expand all | Expand 10 after
2423 exports.LineSplitter = LineSplitter; 2423 exports.LineSplitter = LineSplitter;
2424 exports.StringConversionSink = StringConversionSink; 2424 exports.StringConversionSink = StringConversionSink;
2425 exports.ClosableStringSink = ClosableStringSink; 2425 exports.ClosableStringSink = ClosableStringSink;
2426 exports.UNICODE_REPLACEMENT_CHARACTER_RUNE = UNICODE_REPLACEMENT_CHARACTER_RUN E; 2426 exports.UNICODE_REPLACEMENT_CHARACTER_RUNE = UNICODE_REPLACEMENT_CHARACTER_RUN E;
2427 exports.UNICODE_BOM_CHARACTER_RUNE = UNICODE_BOM_CHARACTER_RUNE; 2427 exports.UNICODE_BOM_CHARACTER_RUNE = UNICODE_BOM_CHARACTER_RUNE;
2428 exports.UTF8 = UTF8; 2428 exports.UTF8 = UTF8;
2429 exports.Utf8Codec = Utf8Codec; 2429 exports.Utf8Codec = Utf8Codec;
2430 exports.Utf8Encoder = Utf8Encoder; 2430 exports.Utf8Encoder = Utf8Encoder;
2431 exports.Utf8Decoder = Utf8Decoder; 2431 exports.Utf8Decoder = Utf8Decoder;
2432 })(convert || (convert = {})); 2432 })(convert || (convert = {}));
OLDNEW
« no previous file with comments | « lib/runtime/dart/collection.js ('k') | lib/runtime/dart/core.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698