开发者

Is there a way in Eclipse CDT to make the IDE parser to read ifndef sections?

I have a section like the following:

#ifndef __CUSTOM_TYPE
typedef unsigned int u_int;
#endif

The IDE doesn't parse it althoug开发者_如何学Ch there is no __CUSTOM_TYPE defined. Then it reports the usage of u_int as an error. Thanks in advance


In principle that should work. Assuming the file is correctly configured to be a C file in a C project (i.e. has a .c icon), CDT shows by colour coding which lines it is counting as part of the selected build configuration. So if __CUSTOM_TYPE is not defined, the following line should have a different background colour.

If that is not the case, hovering over the __CUSTOM_TYPE symbol should bring up an indication of where it is defined - perhaps in some nested header file or something.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜