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

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

Issue 880973005: Support async/await in dart2dart. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Updated cf. comment + status for new_backend Created 5 years, 10 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 library leg_apiimpl; 5 library leg_apiimpl;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 8
9 import '../compiler.dart' as api; 9 import '../compiler.dart' as api;
10 import 'dart2jslib.dart' as leg; 10 import 'dart2jslib.dart' as leg;
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
99 if (!libraryRoot.path.endsWith("/")) { 99 if (!libraryRoot.path.endsWith("/")) {
100 throw new ArgumentError("[libraryRoot] must end with a /."); 100 throw new ArgumentError("[libraryRoot] must end with a /.");
101 } 101 }
102 if (packageRoot == null) { 102 if (packageRoot == null) {
103 throw new ArgumentError("[packageRoot] is null."); 103 throw new ArgumentError("[packageRoot] is null.");
104 } 104 }
105 if (!packageRoot.path.endsWith("/")) { 105 if (!packageRoot.path.endsWith("/")) {
106 throw new ArgumentError("[packageRoot] must end with a /."); 106 throw new ArgumentError("[packageRoot] must end with a /.");
107 } 107 }
108 if (!analyzeOnly) { 108 if (!analyzeOnly) {
109 if (enableAsyncAwait) { 109 if (enableAsyncAwait && emitJavaScript) {
110 throw new ArgumentError( 110 throw new ArgumentError(
111 "--enable-async is currently only supported with --analyze-only"); 111 "--enable-async is currently only supported with --analyze-only");
112 } 112 }
113 if (allowNativeExtensions) { 113 if (allowNativeExtensions) {
114 throw new ArgumentError( 114 throw new ArgumentError(
115 "--allow-native-extensions is only supported in combination with " 115 "--allow-native-extensions is only supported in combination with "
116 "--analyze-only"); 116 "--analyze-only");
117 } 117 }
118 } 118 }
119 } 119 }
(...skipping 285 matching lines...) Expand 10 before | Expand all | Expand 10 after
405 print('$message: ${tryToString(exception)}'); 405 print('$message: ${tryToString(exception)}');
406 print(tryToString(stackTrace)); 406 print(tryToString(stackTrace));
407 } 407 }
408 408
409 fromEnvironment(String name) => environment[name]; 409 fromEnvironment(String name) => environment[name];
410 410
411 LibraryInfo lookupLibraryInfo(String libraryName) { 411 LibraryInfo lookupLibraryInfo(String libraryName) {
412 return library_info.LIBRARIES[libraryName]; 412 return library_info.LIBRARIES[libraryName];
413 } 413 }
414 } 414 }
OLDNEW
« no previous file with comments | « no previous file | pkg/compiler/lib/src/compiler.dart » ('j') | tests/language/async_await_syntax_test.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698