xiaoxiang781216 commented on code in PR #7025: URL: https://github.com/apache/incubator-nuttx/pull/7025#discussion_r965487230
########## include/nuttx/lib/math.h: ########## @@ -81,11 +81,17 @@ #define INFINITY_F (1.0F/0.0F) #define NAN_F (0.0F/0.0F) +#define INFINITY_L (1.0L/0.0L) +#define NAN_L (0.0L/0.0L) + #define isnan(x) ((x) != (x)) #define isinf(x) (((x) == INFINITY) || ((x) == -INFINITY)) -#define isfinite(x) (!(isinf(x) || isnan(x))) - #define isinf_f(x) (((x) == INFINITY_F) || ((x) == -INFINITY_F)) +#define isinf_l(x) (((x) == INFINITY_L) || ((x) == -INFINITY_L)) Review Comment: let follow the standard naming? https://linux.die.net/man/3/finite: ``` int finite(double x); int finitef(float x); int finitel(long double x); int isinf(double x); int isinff(float x); int isinfl(long double x); int isnan(double x); int isnanf(float x); int isnanl(long double x); ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org