Open
Description
For the same reason of prohibiting to override toString()
, it is very confusing.
inline class Id {
final int value;
Id(this.value);
bool get isEven => value.isOdd; // lying. Should this be a target of lint?
}
main() {
Id id = Id(123);
print(id.isEven); // true (deceived)
dynamic d = id;
print(d.isEven); // false
}