Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OTP compatibility and dialyzer issues #1

Open
wants to merge 2 commits into
base: nhse-develop
Choose a base branch
from

Conversation

martinsumner
Copy link

There are two OTP compatibility issues:

  • The [short] option on float_to_binary, is not available until OTP 25. Without converting floats to-and-from may not return the same results. As we don't include floats in JSON in Riak, we wrok around this for earlier versions, and disable the relevant tests.
  • The binary_to_atom/1 and binary_to_existing_atom/1 are not available in OTP 22 - so the equivalent 2-arity function is used. Again there is no conversion of atoms in Riak's use - and so this is not relevant.

The remaining issue is a large number of dialyzer warnings about improper lists. See OTP discussion on this warning - erlang/otp#5937. I'm not sure of the relevance, so rather than attempt to "fix" the code, the decision here is to trust the code and disable the warning.

Breaks behaviour (e.g. float conversion) for earlier OTP versions, but will still compile/run.

In Riak use case, no issues with float conversion or non-utf8 atom conversion.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant