mirror of
https://github.com/dart-lang/sdk
synced 2024-10-14 16:13:19 +00:00
quick fix for INVALID_MODIFIER_ON_SETTER
See: https://github.com/dart-lang/sdk/issues/55917 Change-Id: Ieabdb7b9d12ef409d99497a32b6701a89c936434 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/370481 Commit-Queue: Phil Quitslund <pquitslund@google.com> Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
This commit is contained in:
parent
847c35612a
commit
fb3016a584
|
@ -45,8 +45,8 @@
|
|||
#
|
||||
# Stats:
|
||||
# - 42 "needsEvaluation"
|
||||
# - 331 "needsFix"
|
||||
# - 417 "hasFix"
|
||||
# - 330 "needsFix"
|
||||
# - 418 "hasFix"
|
||||
# - 516 "noFix"
|
||||
|
||||
AnalysisOptionsErrorCode.INCLUDED_FILE_PARSE_ERROR:
|
||||
|
@ -973,9 +973,7 @@ CompileTimeErrorCode.INVALID_MACRO_APPLICATION_TARGET:
|
|||
CompileTimeErrorCode.INVALID_MODIFIER_ON_CONSTRUCTOR:
|
||||
status: hasFix
|
||||
CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER:
|
||||
status: needsFix
|
||||
notes: |-
|
||||
Remove the modifier.
|
||||
status: hasFix
|
||||
CompileTimeErrorCode.INVALID_OVERRIDE:
|
||||
status: hasFix
|
||||
CompileTimeErrorCode.INVALID_OVERRIDE_SETTER:
|
||||
|
|
|
@ -1035,6 +1035,9 @@ final _builtInNonLintProducers = <ErrorCode, List<ProducerGenerator>>{
|
|||
CompileTimeErrorCode.INVALID_MODIFIER_ON_CONSTRUCTOR: [
|
||||
RemoveLexeme.modifier,
|
||||
],
|
||||
CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER: [
|
||||
RemoveLexeme.modifier,
|
||||
],
|
||||
CompileTimeErrorCode.INVALID_USE_OF_COVARIANT: [
|
||||
RemoveLexeme.keyword,
|
||||
],
|
||||
|
|
|
@ -332,6 +332,19 @@ class A {
|
|||
''');
|
||||
}
|
||||
|
||||
Future<void> test_invalidModifierOnSetter() async {
|
||||
await resolveTestCode('''
|
||||
class C {
|
||||
set x(v) async {}
|
||||
}
|
||||
''');
|
||||
await assertHasFix('''
|
||||
class C {
|
||||
set x(v) {}
|
||||
}
|
||||
''');
|
||||
}
|
||||
|
||||
Future<void> test_invalidUseOfCovariant() async {
|
||||
await resolveTestCode('''
|
||||
class C {
|
||||
|
|
Loading…
Reference in a new issue