sdk
sdk copied to clipboard
Missing quick-fixes on pattern destructuring
Repro:
// other.dart
class A {}
void f(A a) {
switch (a) {
case A(value:int other):
break;
}
}
// import.dart
import 'other.dart';
extension Ext on A {
int? get value => null;
}
If the type is declared somewhere else where we can't edit (SDK or a package), then neither the Create field/Create getter fixes show up.
Missing here:
- Create extension quick-fixes
- Add import for the extension
FYI @bwilkerson @DanTup