Discussion :: C Preprocessor - Yes / No Questions (Q.No.2)
Would the following typedef work?
Answer: Option B
Because typedef goes to work after preprocessing.
|Mohamed A said: (May 5, 2014)|
|Why can any one explain ?
typedef is written in preprocessor space and should be treated as #define for example ?
|Ramya said: (Oct 27, 2015)|
|Please clear explanation.|
|Ridha said: (Aug 5, 2016)|
|typedef struct name
Now you can treat the name as a datatype.
But it's done after the preprocessing and #include is replaced by exact files during preprocessing hence wrong.
|Deepa.L said: (Oct 20, 2018)|
|Please explain more about it with the example code.|
Post your comments here:
Email : (optional)
» Your comments will be displayed only after manual approval.