We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
-spec integer_to_scientific(integer()) -> sci_int(). integer_to_scientific(I) -> %% Find exponent and significand {Exp, Significand} = integer_to_scientific(I, 3), case Exp >= 0 of true -> %% 1st byte: exponent, next 3 bytes: significand (Exp bsl 24) + Significand; false -> %% flip sign bit in significand ((-Exp) bsl 24) + 16#800000 + Significand end.
Since sci_int is 4 bytes as with BTC.
The text was updated successfully, but these errors were encountered:
That looks like a copy-paste artifact, 4 bytes should be enough...
This is tracked here https://www.pivotaltracker.com/story/show/161211831
Sorry, something went wrong.
No branches or pull requests
Since sci_int is 4 bytes as with BTC.
The text was updated successfully, but these errors were encountered: