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

Unified Diff: pkg/analysis_server/lib/src/services/refactoring/rename.dart

Issue 2963173002: Pass target elements being renamed into validator. (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
« no previous file with comments | « no previous file | pkg/analysis_server/lib/src/services/refactoring/rename_local.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analysis_server/lib/src/services/refactoring/rename.dart
diff --git a/pkg/analysis_server/lib/src/services/refactoring/rename.dart b/pkg/analysis_server/lib/src/services/refactoring/rename.dart
index 4d7eb1b6894235f2184cf23ef02b4efff818c97d..7ab6eca2a39af939d570a223c78d58351484ab43 100644
--- a/pkg/analysis_server/lib/src/services/refactoring/rename.dart
+++ b/pkg/analysis_server/lib/src/services/refactoring/rename.dart
@@ -18,25 +18,6 @@ import 'package:analyzer_plugin/utilities/range_factory.dart';
import 'package:path/path.dart' as pathos;
/**
- * Returns `true` if two given [Element]s are [LocalElement]s and have
- * intersecting with visibility ranges.
- */
-bool haveIntersectingRanges(LocalElement localElement, Element element) {
- if (element is! LocalElement) {
- return false;
- }
- LocalElement localElement2 = element as LocalElement;
- Source localSource = localElement.source;
- Source localSource2 = localElement2.source;
- SourceRange localRange = localElement.visibleRange;
- SourceRange localRange2 = localElement2.visibleRange;
- return localSource2 == localSource &&
- localRange != null &&
- localRange2 != null &&
- localRange2.intersects(localRange);
-}
-
-/**
* Checks if [element] is defined in the library containing [source].
*/
bool isDefinedInLibrary(
« no previous file with comments | « no previous file | pkg/analysis_server/lib/src/services/refactoring/rename_local.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698