The min, max, and abs macros need total parens outside the expression, otherwise they're buggy.
For example:
if (abs(a) >= 512)
This produces wrong results with the current macros.
Maths.h bug, missing parens
Moderator: Stef
-
- Very interested
- Posts: 3131
- Joined: Thu Nov 30, 2006 9:46 pm
- Location: France - Sevres
- Contact:
Re: Maths.h bug, missing parens
indeed, thanks for pointing that !