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

Side by Side Diff: pkg/analyzer/test/src/context/mock_sdk.dart

Issue 2904263003: Implement type inference for await expressions in front_end. (Closed)
Patch Set: Created 3 years, 6 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 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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 analyzer.test.src.context.mock_sdk; 5 library analyzer.test.src.context.mock_sdk;
6 6
7 import 'package:analyzer/file_system/file_system.dart' as resource; 7 import 'package:analyzer/file_system/file_system.dart' as resource;
8 import 'package:analyzer/file_system/memory_file_system.dart' as resource; 8 import 'package:analyzer/file_system/memory_file_system.dart' as resource;
9 import 'package:analyzer/src/context/cache.dart'; 9 import 'package:analyzer/src/context/cache.dart';
10 import 'package:analyzer/src/context/context.dart'; 10 import 'package:analyzer/src/context/context.dart';
(...skipping 25 matching lines...) Expand all
36 ''' 36 '''
37 library dart.async; 37 library dart.async;
38 38
39 import 'dart:math'; 39 import 'dart:math';
40 40
41 part 'stream.dart'; 41 part 'stream.dart';
42 42
43 class Future<T> { 43 class Future<T> {
44 factory Future(computation()) => null; 44 factory Future(computation()) => null;
45 factory Future.delayed(Duration duration, [T computation()]) => null; 45 factory Future.delayed(Duration duration, [T computation()]) => null;
46 factory Future.value([value]) => null; 46 factory Future.value([FutureOr<T> result]) => null;
47 47
48 static Future<List/*<T>*/> wait/*<T>*/( 48 static Future<List/*<T>*/> wait/*<T>*/(
49 Iterable<Future/*<T>*/> futures) => null; 49 Iterable<Future/*<T>*/> futures) => null;
50 Future/*<R>*/ then/*<R>*/(FutureOr/*<R>*/ onValue(T value)) => null; 50 Future/*<R>*/ then/*<R>*/(FutureOr/*<R>*/ onValue(T value)) => null;
51 51
52 Future<T> whenComplete(action()); 52 Future<T> whenComplete(action());
53 } 53 }
54 54
55 class FutureOr<T> {} 55 class FutureOr<T> {}
56 56
(...skipping 572 matching lines...) Expand 10 before | Expand all | Expand 10 after
629 629
630 @override 630 @override
631 AnalysisCache createCacheFromSourceFactory(SourceFactory factory) { 631 AnalysisCache createCacheFromSourceFactory(SourceFactory factory) {
632 if (factory == null) { 632 if (factory == null) {
633 return super.createCacheFromSourceFactory(factory); 633 return super.createCacheFromSourceFactory(factory);
634 } 634 }
635 return new AnalysisCache( 635 return new AnalysisCache(
636 <CachePartition>[AnalysisEngine.instance.partitionManager.forSdk(sdk)]); 636 <CachePartition>[AnalysisEngine.instance.partitionManager.forSdk(sdk)]);
637 } 637 }
638 } 638 }
OLDNEW
« no previous file with comments | « pkg/analyzer/test/generated/strong_mode_test.dart ('k') | pkg/analyzer/test/src/task/strong/checker_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698