Closed
Description
The following test works in CFE but fails in analyzer
// SharedOptions=--enable-experiment=inline-class
class C {
BoolET operator ==(Object? other) {
return BoolET(other == this);
}
}
extension type BoolET(bool b) implements bool {}
main() {
BoolET b = C() == C(); // No expected error in analyzer
// ^
// [analyzer] unspecified
// [cfe] unspecified
}
According to the Dart spec "The static type of an equality expression is bool", so there should be an error here