Dart 2: Difference between Future<void> and Future<Null> Dart 2: Difference between Future<void> and Future<Null> dart dart

Dart 2: Difference between Future<void> and Future<Null>


The type Null only allows the value null

The type void allows values of any type, but communicates that the value shouldn't be used.

It's not yet clear to me how tools support will treat void. There will probably linter rules that hint or warn at using void values.

Null was used instead of void previously because void was only supported as return type of methods/functions.