Cannot understand warnings in Gradient

The first thing about the warning looks like just a warning in the gradient’s source, not yours.

The second thing is because Access.get is how elixir desugars things like what looks like array accesses, so typing @spec getTipPercentage(List[String.t()]) :: non_neg_integer is actually typing @spec getTipPercentage(Access.get(List, String.t())) :: non_neg_integer, which doesn’t make much sense as a type. ^.^;

But yeah, that’s not an issue for erlang code, it’s just some of Elixir’s magic making the type error a bit weird.

2 Likes