-
Notifications
You must be signed in to change notification settings - Fork 188
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Stop using INT_MIN/INT_MAX for floats (#2094)
INT_MIN/INT_MAX are meant for the int type, and thus casting them to a different type (float) means loss of precision which may lead to failed comparisons later on. Instead use the proper limits using std::numeric_limits.
- Loading branch information
Showing
1 changed file
with
7 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters