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

Unified Diff: pkg/analyzer_plugin/lib/src/utilities/change_builder/change_builder_dart.dart

Issue 2962223002: Remove timeStamp from the ChangeBuilder API (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 side-by-side diff with in-line comments
Download patch
Index: pkg/analyzer_plugin/lib/src/utilities/change_builder/change_builder_dart.dart
diff --git a/pkg/analyzer_plugin/lib/src/utilities/change_builder/change_builder_dart.dart b/pkg/analyzer_plugin/lib/src/utilities/change_builder/change_builder_dart.dart
index c0e7ae08b602c7c36ce67a2f546616a36af670f3..16bd03415f9d90c83f811dde80d802cd9a5f1900 100644
--- a/pkg/analyzer_plugin/lib/src/utilities/change_builder/change_builder_dart.dart
+++ b/pkg/analyzer_plugin/lib/src/utilities/change_builder/change_builder_dart.dart
@@ -40,15 +40,15 @@ class DartChangeBuilderImpl extends ChangeBuilderImpl
DartChangeBuilderImpl(this.driver);
@override
- Future<Null> addFileEdit(String path, int fileStamp,
- void buildFileEdit(DartFileEditBuilder builder)) =>
- super.addFileEdit(path, fileStamp, buildFileEdit);
+ Future<Null> addFileEdit(
+ String path, void buildFileEdit(DartFileEditBuilder builder)) =>
+ super.addFileEdit(path, buildFileEdit);
@override
- Future<DartFileEditBuilderImpl> createFileEditBuilder(
- String path, int fileStamp) async {
+ Future<DartFileEditBuilderImpl> createFileEditBuilder(String path) async {
AnalysisResult result = await driver.getResult(path);
- return new DartFileEditBuilderImpl(this, path, fileStamp, result.unit);
+ int timeStamp = driver.fsState.getFileForPath(path).exists ? 0 : -1;
+ return new DartFileEditBuilderImpl(this, path, timeStamp, result.unit);
}
}

Powered by Google App Engine
This is Rietveld 408576698