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

Unified Diff: pkg/analysis_services/lib/src/correction/source_range.dart

Issue 405483007: More fixes in the Fixes service. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 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/analysis_services/lib/src/correction/source_range.dart
diff --git a/pkg/analysis_services/lib/correction/source_range_factory.dart b/pkg/analysis_services/lib/src/correction/source_range.dart
similarity index 92%
rename from pkg/analysis_services/lib/correction/source_range_factory.dart
rename to pkg/analysis_services/lib/src/correction/source_range.dart
index 4637ed8d484ccbc342b65d7f93cdcf91a351e2ce..c1a8bb5cc422beed9a090271d75ab1115b24a4b9 100644
--- a/pkg/analysis_services/lib/correction/source_range_factory.dart
+++ b/pkg/analysis_services/lib/src/correction/source_range.dart
@@ -5,7 +5,7 @@
// This code was auto-generated, is not intended to be edited, and is subject to
// significant change. Please see the README file for more information.
-library services.correction.source_range_factory;
+library services.src.correction.source_range_factory;
import 'package:analyzer/src/generated/ast.dart';
import 'package:analyzer/src/generated/element.dart';
@@ -52,8 +52,9 @@ SourceRange rangeNodes(List<AstNode> nodes) {
}
SourceRange rangeStartEnd(a, b) {
- int offset = a.offset;
- var length = b.end - offset;
+ int offset = a is int ? a : a.offset;
+ int end = b is int ? b : b.end;
+ var length = end - offset;
return new SourceRange(offset, length);
}

Powered by Google App Engine
This is Rietveld 408576698