Constant forwarding constructors could be supported #27061
Labels
area-language
Dart language related items (some items might be better tracked at github.com/dart-lang/language).
closed-duplicate
Closed in favor of an existing report
type-enhancement
A request for a change that isn't a bug
Currently constant forwarding constructors are not supported, which seems like an oversight.
For instance:
const C()
is not allowed since the super constructor (S+M) is not constant. This could be supported if the constness of the S constructor propagated to the forwarding S+M constructor where feasible.The text was updated successfully, but these errors were encountered: