7

After upgrading to 0.40.0 I started getting an awkward asterisk suffix sign after any type.

Example...

print(elementInstance.type.toString());

I used to get Stream<bool> now I'm getting Stream<bool*>*

Do I miss any analyzer settings or dart formatting?

Thanks in advance.

ddiev
  • 81
  • 4

2 Answers2

3

It says just that a variable could be either nullable or non nullable because such behaviour was before NNBD (Dart v.2.12) where you have to explicitly mark a variable with question mark if it is nullable

Check out this article https://dart.dev/null-safety

Andrey Gritsay
  • 979
  • 1
  • 10
  • 18
1

We can simply use Element's new method getDisplayString() which has a bool parameter withNullability.

Based on the @Andrey Gritsay's comment I conducted a quick debug into the analyzer package and found it.

ddiev
  • 81
  • 4