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

Side by Side Diff: pkg/analyzer/lib/src/generated/error.dart

Issue 2232863004: Create new error message for missing generated files (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 4 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 unified diff | Download patch
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 analyzer.src.generated.error; 5 library analyzer.src.generated.error;
6 6
7 import 'dart:collection'; 7 import 'dart:collection';
8 8
9 import 'package:analyzer/dart/ast/ast.dart' show AstNode; 9 import 'package:analyzer/dart/ast/ast.dart' show AstNode;
10 import 'package:analyzer/dart/ast/token.dart'; 10 import 'package:analyzer/dart/ast/token.dart';
(...skipping 2355 matching lines...) Expand 10 before | Expand all | Expand 10 after
2366 * 2366 *
2367 * 14.1 Imports: It is a compile-time error if the compilation unit found at 2367 * 14.1 Imports: It is a compile-time error if the compilation unit found at
2368 * the specified URI is not a library declaration. 2368 * the specified URI is not a library declaration.
2369 * 2369 *
2370 * 14.3 Parts: It is a compile time error if the contents of the URI are not a 2370 * 14.3 Parts: It is a compile time error if the contents of the URI are not a
2371 * valid part declaration. 2371 * valid part declaration.
2372 * 2372 *
2373 * Parameters: 2373 * Parameters:
2374 * 0: the URI pointing to a non-existent file 2374 * 0: the URI pointing to a non-existent file
2375 * 2375 *
2376 * See [INVALID_URI]. 2376 * See [INVALID_URI], [URI_HAS_NOT_BEEN_GENERATED].
2377 */ 2377 */
2378 static const CompileTimeErrorCode URI_DOES_NOT_EXIST = 2378 static const CompileTimeErrorCode URI_DOES_NOT_EXIST =
2379 const CompileTimeErrorCode( 2379 const CompileTimeErrorCode(
2380 'URI_DOES_NOT_EXIST', "Target of URI does not exist: '{0}'"); 2380 'URI_DOES_NOT_EXIST', "Target of URI does not exist: '{0}'");
2381 2381
2382 /** 2382 /**
2383 * Just like [URI_DOES_NOT_EXIST], but used when the URI refers to a file that
2384 * is expected to be generated.
2385 *
2386 * Parameters:
2387 * 0: the URI pointing to a non-existent file
2388 *
2389 * See [INVALID_URI], [URI_DOES_NOT_EXIST].
2390 */
2391 static const CompileTimeErrorCode URI_HAS_NOT_BEEN_GENERATED =
2392 const CompileTimeErrorCode('URI_HAS_NOT_BEEN_GENERATED',
2393 "Target of URI has not been generated: '{0}'");
2394
2395 /**
2383 * 14.1 Imports: It is a compile-time error if <i>x</i> is not a compile-time 2396 * 14.1 Imports: It is a compile-time error if <i>x</i> is not a compile-time
2384 * constant, or if <i>x</i> involves string interpolation. 2397 * constant, or if <i>x</i> involves string interpolation.
2385 * 2398 *
2386 * 14.3 Parts: It is a compile-time error if <i>s</i> is not a compile-time 2399 * 14.3 Parts: It is a compile-time error if <i>s</i> is not a compile-time
2387 * constant, or if <i>s</i> involves string interpolation. 2400 * constant, or if <i>s</i> involves string interpolation.
2388 * 2401 *
2389 * 14.5 URIs: It is a compile-time error if the string literal <i>x</i> that 2402 * 14.5 URIs: It is a compile-time error if the string literal <i>x</i> that
2390 * describes a URI is not a compile-time constant, or if <i>x</i> involves 2403 * describes a URI is not a compile-time constant, or if <i>x</i> involves
2391 * string interpolation. 2404 * string interpolation.
2392 */ 2405 */
(...skipping 1886 matching lines...) Expand 10 before | Expand all | Expand 10 after
4279 * 0: the lexeme of the logical operator 4292 * 0: the lexeme of the logical operator
4280 */ 4293 */
4281 static const StaticTypeWarningCode NON_BOOL_OPERAND = 4294 static const StaticTypeWarningCode NON_BOOL_OPERAND =
4282 const StaticTypeWarningCode('NON_BOOL_OPERAND', 4295 const StaticTypeWarningCode('NON_BOOL_OPERAND',
4283 "The operands of the '{0}' operator must be assignable to 'bool'"); 4296 "The operands of the '{0}' operator must be assignable to 'bool'");
4284 4297
4285 /** 4298 /**
4286 * 4299 *
4287 */ 4300 */
4288 static const StaticTypeWarningCode NON_NULLABLE_FIELD_NOT_INITIALIZED = 4301 static const StaticTypeWarningCode NON_NULLABLE_FIELD_NOT_INITIALIZED =
4289 const StaticTypeWarningCode( 4302 const StaticTypeWarningCode('NON_NULLABLE_FIELD_NOT_INITIALIZED',
4290 'NON_NULLABLE_FIELD_NOT_INITIALIZED',
4291 "Variable '{0}' of non-nullable type '{1}' must be initialized"); 4303 "Variable '{0}' of non-nullable type '{1}' must be initialized");
4292 4304
4293 /** 4305 /**
4294 * 15.8 Parameterized Types: It is a static type warning if <i>A<sub>i</sub>, 4306 * 15.8 Parameterized Types: It is a static type warning if <i>A<sub>i</sub>,
4295 * 1 &lt;= i &lt;= n</i> does not denote a type in the enclosing lexical scope . 4307 * 1 &lt;= i &lt;= n</i> does not denote a type in the enclosing lexical scope .
4296 */ 4308 */
4297 static const StaticTypeWarningCode NON_TYPE_AS_TYPE_ARGUMENT = 4309 static const StaticTypeWarningCode NON_TYPE_AS_TYPE_ARGUMENT =
4298 const StaticTypeWarningCode('NON_TYPE_AS_TYPE_ARGUMENT', 4310 const StaticTypeWarningCode('NON_TYPE_AS_TYPE_ARGUMENT',
4299 "The name '{0}' is not a type and cannot be used as a parameterized ty pe"); 4311 "The name '{0}' is not a type and cannot be used as a parameterized ty pe");
4300 4312
(...skipping 1822 matching lines...) Expand 10 before | Expand all | Expand 10 after
6123 * Initialize a newly created error code to have the given [name]. 6135 * Initialize a newly created error code to have the given [name].
6124 */ 6136 */
6125 const TodoCode(String name) : super(name, "{0}"); 6137 const TodoCode(String name) : super(name, "{0}");
6126 6138
6127 @override 6139 @override
6128 ErrorSeverity get errorSeverity => ErrorSeverity.INFO; 6140 ErrorSeverity get errorSeverity => ErrorSeverity.INFO;
6129 6141
6130 @override 6142 @override
6131 ErrorType get type => ErrorType.TODO; 6143 ErrorType get type => ErrorType.TODO;
6132 } 6144 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698