| Index: pkg/compiler/lib/src/warnings.dart
|
| diff --git a/pkg/compiler/lib/src/warnings.dart b/pkg/compiler/lib/src/warnings.dart
|
| index 8977b5d9220dfd3a363dbf728a4cec8f805dcfaa..3f47f629e6fc0101931619652e3e04abe728e991 100644
|
| --- a/pkg/compiler/lib/src/warnings.dart
|
| +++ b/pkg/compiler/lib/src/warnings.dart
|
| @@ -1175,6 +1175,15 @@ main() => new C();"""]);
|
| static const MessageKind ASSIGNING_TYPE = const MessageKind(
|
| "Cannot assign a value to a type.");
|
|
|
| + static const MessageKind IF_NULL_ASSIGNING_TYPE = const MessageKind(
|
| + "Cannot assign a value to a type. Note that types are never null, "
|
| + "so this ??= assignment has no effect.",
|
| + howToFix: "Try removing the '??=' assignment.",
|
| + options: const ['--enable-null-aware-operators'],
|
| + examples: const [
|
| + "class A {} main() { print(A ??= 3);}",
|
| + ]);
|
| +
|
| static const MessageKind VOID_NOT_ALLOWED = const MessageKind(
|
| "Type 'void' can't be used here because it isn't a return type.",
|
| howToFix: "Try removing 'void' keyword or replace it with 'var', 'final',"
|
| @@ -1969,6 +1978,10 @@ main() => r\"\"\"
|
| // This is a fall-back message that shouldn't happen.
|
| "Incomplete token.");
|
|
|
| + static const MessageKind NULL_AWARE_OPERATORS_DISABLED = const MessageKind(
|
| + "Null-aware operators like '#{operator}' are currently experimental. "
|
| + "You can enable them using the --enable-null-aware-operators flag.");
|
| +
|
| static const MessageKind EXPONENT_MISSING = const MessageKind(
|
| "Numbers in exponential notation should always contain an exponent"
|
| " (an integer number with an optional sign).",
|
|
|