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

Unexpected rounding behavior in getiparam() #143

Open
shubhambhatnag opened this issue Apr 11, 2024 · 0 comments
Open

Unexpected rounding behavior in getiparam() #143

shubhambhatnag opened this issue Apr 11, 2024 · 0 comments

Comments

@shubhambhatnag
Copy link
Contributor

getiparam() rounds floating point numbers up to the nearing integer, instead of the C standard of flooring the value to the closest integer less than the floating point value.

Ex. int var = getiparam("c"); (Where c is 3.5) sets var to 4, instead of 3 as would be done with a cast to int in C.

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