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

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

Issue 1024073003: Treat Object and dynamic similarly (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
« no previous file with comments | « lib/runtime/dart/collection.js ('k') | lib/src/checker/rules.dart » ('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 = new AsciiCodec(); 4 let ASCII = 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 799 matching lines...) Expand 10 before | Expand all | Expand 10 after
810 this[_reviver] = reviver; 810 this[_reviver] = reviver;
811 super.Converter(); 811 super.Converter();
812 } 812 }
813 convert(input) { 813 convert(input) {
814 return _parseJson(input, this[_reviver]); 814 return _parseJson(input, this[_reviver]);
815 } 815 }
816 startChunkedConversion(sink) { 816 startChunkedConversion(sink) {
817 return new _JsonDecoderSink(this[_reviver], sink); 817 return new _JsonDecoderSink(this[_reviver], sink);
818 } 818 }
819 bind(stream) { 819 bind(stream) {
820 return dart.as(super.bind(stream), async.Stream$(core.Object)); 820 return super.bind(stream);
821 } 821 }
822 } 822 }
823 // Function _parseJson: (String, (dynamic, dynamic) → dynamic) → dynamic 823 // Function _parseJson: (String, (dynamic, dynamic) → dynamic) → dynamic
824 function _parseJson(source, reviver) { 824 function _parseJson(source, reviver) {
825 if (!(typeof source == string)) 825 if (!(typeof source == string))
826 throw new core.ArgumentError(source); 826 throw new core.ArgumentError(source);
827 let parsed = null; 827 let parsed = null;
828 try { 828 try {
829 parsed = JSON.parse(source); 829 parsed = JSON.parse(source);
830 } catch (e) { 830 } catch (e) {
(...skipping 1490 matching lines...) Expand 10 before | Expand all | Expand 10 after
2321 exports.LineSplitter = LineSplitter; 2321 exports.LineSplitter = LineSplitter;
2322 exports.StringConversionSink = StringConversionSink; 2322 exports.StringConversionSink = StringConversionSink;
2323 exports.ClosableStringSink = ClosableStringSink; 2323 exports.ClosableStringSink = ClosableStringSink;
2324 exports.UNICODE_REPLACEMENT_CHARACTER_RUNE = UNICODE_REPLACEMENT_CHARACTER_RUN E; 2324 exports.UNICODE_REPLACEMENT_CHARACTER_RUNE = UNICODE_REPLACEMENT_CHARACTER_RUN E;
2325 exports.UNICODE_BOM_CHARACTER_RUNE = UNICODE_BOM_CHARACTER_RUNE; 2325 exports.UNICODE_BOM_CHARACTER_RUNE = UNICODE_BOM_CHARACTER_RUNE;
2326 exports.UTF8 = UTF8; 2326 exports.UTF8 = UTF8;
2327 exports.Utf8Codec = Utf8Codec; 2327 exports.Utf8Codec = Utf8Codec;
2328 exports.Utf8Encoder = Utf8Encoder; 2328 exports.Utf8Encoder = Utf8Encoder;
2329 exports.Utf8Decoder = Utf8Decoder; 2329 exports.Utf8Decoder = Utf8Decoder;
2330 })(convert || (convert = {})); 2330 })(convert || (convert = {}));
OLDNEW
« no previous file with comments | « lib/runtime/dart/collection.js ('k') | lib/src/checker/rules.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698