[Solved] What is the scope of pre-compiler define in c++?
test2.hpp and test.hpp both #include test1.hpp. If the scope of test1_hpp is the whole application, as far as I understand, there can only one include test1.hpp success. Because once included, test1_hpp is defined. The compiler works on translation units (think: individual .cpp files) not the whole application (think: executable). What you call “the scope of … Read more