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

round/even/to doesn't work on money! #5508

Open
greggirwin opened this issue May 27, 2024 · 0 comments
Open

round/even/to doesn't work on money! #5508

greggirwin opened this issue May 27, 2024 · 0 comments

Comments

@greggirwin
Copy link
Contributor

Describe the bug

>> round/even/to 0.125 0.01
== 0.12
>> round/even/to 0.135 0.01
== 0.14
>> round/even/to $0.125 0.01
== $0.13
>> round/even/to $0.135 0.01
== $0.14

Looks like it just checks the whole value for evenness, not the scale.

_even?     [either all [half? even? value][down][away]]

Expected behavior

Same as for float!

Platform version

-----------RED & PLATFORM VERSION-----------
RED: [ branch: "master" tag: #v0.6.0 ahead: 9031 date: 26-May-2024/2:09:32 commit: #b26ec93344128ae0d49aeb5f6d46ecd5f005631b ]
PLATFORM: [ name: "Windows 10" OS: 'Windows arch: 'x86-64 version: 10.0.0 build: 19045 ]

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

No branches or pull requests

1 participant