This is definitely not what we want
REMEMBER that macros are pure text
replacement they are not function calls-
-
Lack of care will cause nasty problems
For example, cube(a++)expands in the following way:
|
(a++)*(a++)*(a++)
|
This computes the correct value for the cube, but the new
value of a will be:
a+3
after this expression and not a+1 as we might expect
A number of the standard library procedures, like getchar
and putchar are really macros and not procedures -
|