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

Side by Side Diff: pkg/compiler/lib/src/old_to_new_api.dart

Issue 1859343004: dartfmt pkg/compiler (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 8 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 | « pkg/compiler/lib/src/native/ssa.dart ('k') | pkg/compiler/lib/src/ordered_typeset.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 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 /// Implementation of the new compiler API in '../compiler_new.dart' through the 5 /// Implementation of the new compiler API in '../compiler_new.dart' through the
6 /// old compiler API in '../compiler.dart'. 6 /// old compiler API in '../compiler.dart'.
7 7
8 library compiler.api.legacy; 8 library compiler.api.legacy;
9 9
10 import 'dart:async' show EventSink, Future; 10 import 'dart:async' show EventSink, Future;
(...skipping 13 matching lines...) Expand all
24 } 24 }
25 } 25 }
26 26
27 /// Implementation of [CompilerDiagnostics] using a [DiagnosticHandler]. 27 /// Implementation of [CompilerDiagnostics] using a [DiagnosticHandler].
28 class LegacyCompilerDiagnostics implements CompilerDiagnostics { 28 class LegacyCompilerDiagnostics implements CompilerDiagnostics {
29 final DiagnosticHandler _handler; 29 final DiagnosticHandler _handler;
30 30
31 LegacyCompilerDiagnostics(this._handler); 31 LegacyCompilerDiagnostics(this._handler);
32 32
33 @override 33 @override
34 void report(var code, Uri uri, int begin, int end, 34 void report(
35 String message, Diagnostic kind) { 35 var code, Uri uri, int begin, int end, String message, Diagnostic kind) {
36 _handler(uri, begin, end, message, kind); 36 _handler(uri, begin, end, message, kind);
37 } 37 }
38 } 38 }
39 39
40 /// Implementation of [CompilerOutput] using an optional 40 /// Implementation of [CompilerOutput] using an optional
41 /// [CompilerOutputProvider]. 41 /// [CompilerOutputProvider].
42 class LegacyCompilerOutput implements CompilerOutput { 42 class LegacyCompilerOutput implements CompilerOutput {
43 final CompilerOutputProvider _outputProvider; 43 final CompilerOutputProvider _outputProvider;
44 44
45 LegacyCompilerOutput([this._outputProvider]); 45 LegacyCompilerOutput([this._outputProvider]);
46 46
47 @override 47 @override
48 EventSink<String> createEventSink(String name, String extension) { 48 EventSink<String> createEventSink(String name, String extension) {
49 if (_outputProvider != null) return _outputProvider(name, extension); 49 if (_outputProvider != null) return _outputProvider(name, extension);
50 return NullSink.outputProvider(name, extension); 50 return NullSink.outputProvider(name, extension);
51 } 51 }
52 } 52 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/native/ssa.dart ('k') | pkg/compiler/lib/src/ordered_typeset.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698