Inconsistent type inference behavior of block-type vs expression-type closures #29606
Labels
area-analyzer
Use area-analyzer for Dart analyzer issues, including the analysis server and code completion.
area-language
Dart language related items (some items might be better tracked at github.com/dart-lang/language).
language-strong-mode-polish
P2
A bug or feature request we're likely to work on
Consider the following code:
Type inference currently infers a return type of
Object
for the closure ina
, and a return type ofnum
for the closure inb
.The behavior of expression-type closures should be changed to match that of block-type closures.
The text was updated successfully, but these errors were encountered: