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

Side by Side Diff: pkg/analysis_server/lib/src/services/correction/fix.dart

Issue 1393953002: Add 'Add != null' quick fix. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 2 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 unified diff | Download patch
« no previous file with comments | « no previous file | pkg/analysis_server/lib/src/services/correction/fix_internal.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library analysis_server.src.services.correction.fix; 5 library analysis_server.src.services.correction.fix;
6 6
7 import 'package:analysis_server/edit/fix/fix_core.dart'; 7 import 'package:analysis_server/edit/fix/fix_core.dart';
8 import 'package:analysis_server/src/plugin/server_plugin.dart'; 8 import 'package:analysis_server/src/plugin/server_plugin.dart';
9 import 'package:analyzer/file_system/file_system.dart'; 9 import 'package:analyzer/file_system/file_system.dart';
10 import 'package:analyzer/src/generated/engine.dart'; 10 import 'package:analyzer/src/generated/engine.dart';
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
102 static const ADD_ASYNC = 102 static const ADD_ASYNC =
103 const FixKind('ADD_ASYNC', 50, "Add 'async' modifier"); 103 const FixKind('ADD_ASYNC', 50, "Add 'async' modifier");
104 static const ADD_FIELD_FORMAL_PARAMETERS = const FixKind( 104 static const ADD_FIELD_FORMAL_PARAMETERS = const FixKind(
105 'ADD_FIELD_FORMAL_PARAMETERS', 30, "Add final field formal parameters"); 105 'ADD_FIELD_FORMAL_PARAMETERS', 30, "Add final field formal parameters");
106 static const ADD_MISSING_PARAMETER_POSITIONAL = const FixKind( 106 static const ADD_MISSING_PARAMETER_POSITIONAL = const FixKind(
107 'ADD_MISSING_PARAMETER_POSITIONAL', 107 'ADD_MISSING_PARAMETER_POSITIONAL',
108 31, 108 31,
109 "Add optional positional parameter"); 109 "Add optional positional parameter");
110 static const ADD_MISSING_PARAMETER_REQUIRED = const FixKind( 110 static const ADD_MISSING_PARAMETER_REQUIRED = const FixKind(
111 'ADD_MISSING_PARAMETER_REQUIRED', 30, "Add required parameter"); 111 'ADD_MISSING_PARAMETER_REQUIRED', 30, "Add required parameter");
112 static const ADD_NE_NULL = const FixKind('ADD_NE_NULL', 50, "Add != null");
112 static const ADD_PACKAGE_DEPENDENCY = const FixKind( 113 static const ADD_PACKAGE_DEPENDENCY = const FixKind(
113 'ADD_PACKAGE_DEPENDENCY', 50, "Add dependency on package '{0}'"); 114 'ADD_PACKAGE_DEPENDENCY', 50, "Add dependency on package '{0}'");
114 static const ADD_PART_OF = 115 static const ADD_PART_OF =
115 const FixKind('ADD_PART_OF', 50, "Add 'part of' directive"); 116 const FixKind('ADD_PART_OF', 50, "Add 'part of' directive");
116 static const ADD_SUPER_CONSTRUCTOR_INVOCATION = const FixKind( 117 static const ADD_SUPER_CONSTRUCTOR_INVOCATION = const FixKind(
117 'ADD_SUPER_CONSTRUCTOR_INVOCATION', 118 'ADD_SUPER_CONSTRUCTOR_INVOCATION',
118 50, 119 50,
119 "Add super constructor {0} invocation"); 120 "Add super constructor {0} invocation");
120 static const CHANGE_TO = const FixKind('CHANGE_TO', 49, "Change to '{0}'"); 121 static const CHANGE_TO = const FixKind('CHANGE_TO', 49, "Change to '{0}'");
121 static const CHANGE_TO_STATIC_ACCESS = const FixKind( 122 static const CHANGE_TO_STATIC_ACCESS = const FixKind(
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
189 static const USE_CONST = const FixKind('USE_CONST', 50, "Change to constant"); 190 static const USE_CONST = const FixKind('USE_CONST', 50, "Change to constant");
190 static const USE_EFFECTIVE_INTEGER_DIVISION = const FixKind( 191 static const USE_EFFECTIVE_INTEGER_DIVISION = const FixKind(
191 'USE_EFFECTIVE_INTEGER_DIVISION', 192 'USE_EFFECTIVE_INTEGER_DIVISION',
192 50, 193 50,
193 "Use effective integer division ~/"); 194 "Use effective integer division ~/");
194 static const USE_EQ_EQ_NULL = 195 static const USE_EQ_EQ_NULL =
195 const FixKind('USE_EQ_EQ_NULL', 50, "Use == null instead of 'is Null'"); 196 const FixKind('USE_EQ_EQ_NULL', 50, "Use == null instead of 'is Null'");
196 static const USE_NOT_EQ_NULL = 197 static const USE_NOT_EQ_NULL =
197 const FixKind('USE_NOT_EQ_NULL', 50, "Use != null instead of 'is! Null'"); 198 const FixKind('USE_NOT_EQ_NULL', 50, "Use != null instead of 'is! Null'");
198 } 199 }
OLDNEW
« no previous file with comments | « no previous file | pkg/analysis_server/lib/src/services/correction/fix_internal.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698