open-telemetry / opentelemetry-erlang-api

Erlang/Elixir OpenTelemetry API
Apache License 2.0
60 stars 13 forks source link

Update headers typing #79

Closed bryannaegele closed 3 years ago

bryannaegele commented 3 years ago

Update typing for https://github.com/open-telemetry/opentelemetry-erlang/pull/90

tsloughter commented 3 years ago

iodata includes binary(), so this doesn't need to change I think? It can remain the same for the possible future when it can return an iolist?

ferd commented 3 years ago

iodata() is iolist() | binary() and includes both types. Without active breaking calls, it should in theory be fine. However, whenever a literal iolist is being passed to something that accepts just binary without any conversion, dialyzer should pick up on it and start warning.

tsloughter commented 3 years ago

Agh, true, good point. I guess we should merge this then.