Skip to content

Add precision to Float.ceil/1 & Float.floor/1 #2520

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

Merged
merged 1 commit into from
Jul 12, 2014

Conversation

nurugger07
Copy link
Contributor

Float.ceil/1 and Float.floor/1 no longer accepts integers. They now accept a precision argument that defaults to 0 (as in round/2) and always return floats. The documentation of Float.round/2 was updated to cover the use of Kernel.round/1 which accepts both integers and floats, always returns integers and is allowed in guards.

josevalim pushed a commit that referenced this pull request Jul 12, 2014
Add precision to Float.ceil/1 & Float.floor/1
@josevalim josevalim merged commit fc5cf50 into elixir-lang:master Jul 12, 2014
@josevalim
Copy link
Member

❤️ 💚 💙 💛 💜

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants