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

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

Issue 499723002: Implement 'edit.getRefactoring' for rename refactoring. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Tweak for comment Created 6 years, 4 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_server/lib/src/services/refactoring/naming_conventions.dart
diff --git a/pkg/analysis_server/lib/src/services/refactoring/naming_conventions.dart b/pkg/analysis_server/lib/src/services/refactoring/naming_conventions.dart
index b41c151a8d37add7f28223a5d9be2591dbb2d270..2e815fa25b51deaac1faed9aa4fa5b837d01f16e 100644
--- a/pkg/analysis_server/lib/src/services/refactoring/naming_conventions.dart
+++ b/pkg/analysis_server/lib/src/services/refactoring/naming_conventions.dart
@@ -27,7 +27,7 @@ RefactoringStatus validateClassName(String name) {
RefactoringStatus validateConstantName(String name) {
// null
if (name == null) {
- return new RefactoringStatus.error("Constant name must not be null.");
+ return new RefactoringStatus.fatal("Constant name must not be null.");
}
// is not identifier
RefactoringStatus status =
@@ -117,11 +117,11 @@ RefactoringStatus validateImportPrefixName(String name) {
RefactoringStatus validateLibraryName(String name) {
// null
if (name == null) {
- return new RefactoringStatus.error("Library name must not be null.");
+ return new RefactoringStatus.fatal("Library name must not be null.");
}
// blank
if (isBlank(name)) {
- return new RefactoringStatus.error("Library name must not be blank.");
+ return new RefactoringStatus.fatal("Library name must not be blank.");
}
// check identifiers
List<String> identifiers = name.split('.');
@@ -190,7 +190,7 @@ RefactoringStatus _validateIdentifier(String identifier, String desc,
int length = identifier.length;
if (length == 0) {
String message = "$desc must not be empty.";
- return new RefactoringStatus.error(message);
+ return new RefactoringStatus.fatal(message);
}
int currentChar = identifier.codeUnitAt(0);
if (!isLetter(currentChar) &&
@@ -220,7 +220,7 @@ RefactoringStatus _validateLowerCamelCase(String identifier, String desc) {
// null
if (identifier == null) {
String message = "$desc must not be null.";
- return new RefactoringStatus.error(message);
+ return new RefactoringStatus.fatal(message);
}
// is not identifier
RefactoringStatus status =
@@ -253,7 +253,7 @@ RefactoringStatus _validateUpperCamelCase(String identifier, String desc) {
// null
if (identifier == null) {
String message = "$desc must not be null.";
- return new RefactoringStatus.error(message);
+ return new RefactoringStatus.fatal(message);
}
// is not identifier
RefactoringStatus status =
« no previous file with comments | « pkg/analysis_server/lib/src/edit/edit_domain.dart ('k') | pkg/analysis_server/test/edit/refactoring_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698