1. Feb 17, 2009

aostraff

I was wondering if nested header files are achievable in C? I tried placing #include "header.h" inside a header file but I don't think it worked. thanks.

Last edited: Feb 17, 2009
2. Feb 17, 2009

Coin

Yes, that is allowed and it should work.

3. Feb 17, 2009

mgb_phys

It does work, although it should be reduced as much as possible.
It's confusing and leads to long compile times.

To avoid problems of a header being included twice in a . cfile through differnet routes you should put include guards around it.
Code (Text):