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

Unified Diff: pkg/front_end/lib/src/incremental/kernel_driver.dart

Issue 2992173002: Get logger / fileSystem / byteStore from ProcessedOptions. (Closed)
Patch Set: Created 3 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: pkg/front_end/lib/src/incremental/kernel_driver.dart
diff --git a/pkg/front_end/lib/src/incremental/kernel_driver.dart b/pkg/front_end/lib/src/incremental/kernel_driver.dart
index 452c011071152736a71696841c02410f06c7989e..60984505d48cbf7838c97c7823ef1902ee358d8c 100644
--- a/pkg/front_end/lib/src/incremental/kernel_driver.dart
+++ b/pkg/front_end/lib/src/incremental/kernel_driver.dart
@@ -48,6 +48,9 @@ class KernelDriver {
/// The version of data format, should be incremented on every format change.
static const int DATA_VERSION = 1;
+ /// Options used by the kernel compiler.
+ final ProcessedOptions _options;
+
/// The logger to report compilation progress.
final PerformanceLog _logger;
@@ -60,9 +63,6 @@ class KernelDriver {
/// The object that knows how to resolve "package:" and "dart:" URIs.
final UriTranslator _uriTranslator;
- /// Options used by the kernel compiler.
- final ProcessedOptions _options;
-
/// The function that is invoked when a new file is about to be added to
/// the current file state. The [Future] that it returns is awaited before
/// reading the file contents.
@@ -81,10 +81,12 @@ class KernelDriver {
/// The object that provides additional information for tests.
final _TestView _testView = new _TestView();
- KernelDriver(this._logger, this._fileSystem, this._byteStore,
- this._uriTranslator, this._options,
+ KernelDriver(this._options, this._uriTranslator,
{KernelDriverFileAddedFn fileAddedFn})
- : _fileAddedFn = fileAddedFn {
+ : _logger = _options.logger,
+ _fileSystem = _options.fileSystem,
+ _byteStore = _options.byteStore,
+ _fileAddedFn = fileAddedFn {
_computeSalt();
Future<Null> onFileAdded(Uri uri) {

Powered by Google App Engine
This is Rietveld 408576698