double in C preprocessor directives -
what differences between,
#define myvariable 1.25 and,
#define myvariable (double)1.25 while declaring preprocessor directives in c.
the difference preprocessor will, when sees myvariable, substitute in (double)1.25 rather 1.25.
this have no effect on code (possibly bizarre edge cases notwithstanding) since 1.25 already double literal, per c11 6.4.4.2 floating constants /4:
an unsuffixed floating constant has type
double. if suffixed letterforf, has typefloat. if suffixed letterlorl, has typelong double.
Comments
Post a Comment