OLD | NEW |
1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2017, 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 import 'dart:async'; | 5 import 'dart:async'; |
6 | 6 |
7 import 'package:front_end/src/base/processed_options.dart'; | 7 import 'package:front_end/src/base/processed_options.dart'; |
8 import 'package:front_end/src/incremental_kernel_generator_impl.dart'; | 8 import 'package:front_end/src/incremental_kernel_generator_impl.dart'; |
9 import 'package:kernel/kernel.dart'; | 9 import 'package:kernel/kernel.dart'; |
10 | 10 |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
92 /// Creates an [IncrementalKernelGenerator] which is prepared to generate | 92 /// Creates an [IncrementalKernelGenerator] which is prepared to generate |
93 /// kernel representations of the program whose main library is in the given | 93 /// kernel representations of the program whose main library is in the given |
94 /// [entryPoint]. | 94 /// [entryPoint]. |
95 /// | 95 /// |
96 /// The initial "previous program state" is an empty program containing no | 96 /// The initial "previous program state" is an empty program containing no |
97 /// code, and the initial set of valid sources is empty. To obtain a kernel | 97 /// code, and the initial set of valid sources is empty. To obtain a kernel |
98 /// representation of the program, call [computeDelta]. | 98 /// representation of the program, call [computeDelta]. |
99 static Future<IncrementalKernelGenerator> newInstance( | 99 static Future<IncrementalKernelGenerator> newInstance( |
100 CompilerOptions options, Uri entryPoint, | 100 CompilerOptions options, Uri entryPoint, |
101 {WatchUsedFilesFn watch}) async { | 101 {WatchUsedFilesFn watch}) async { |
102 var processedOptions = new ProcessedOptions(options); | 102 var processedOptions = new ProcessedOptions(options, false, [entryPoint]); |
103 var uriTranslator = await processedOptions.getUriTranslator(); | 103 var uriTranslator = await processedOptions.getUriTranslator(); |
104 return new IncrementalKernelGeneratorImpl( | 104 return new IncrementalKernelGeneratorImpl( |
105 processedOptions, uriTranslator, entryPoint, | 105 processedOptions, uriTranslator, entryPoint, |
106 watch: watch); | 106 watch: watch); |
107 } | 107 } |
108 } | 108 } |
OLD | NEW |