Shawn Curry
10-23-2002, 07:10 AM
I have 5 translation units now for my long math class. They all begin and end with:
#ifndef INTEGER_H
#define INTEGER_H
#endif
the individual files have their own symbols, but im having some problems with that statement now. Correct me if im wrong, but I thought that you use #ifndef to make sure your file is compiled once, right? For some reason, I get "LNK2001: Linker could not resolve external symbol: blah blah blah". And then goes on to list all the Whole number class functions that I had been using. Each of my translation units has an #include for everything it uses, and the only way I can compile is if I lose the #ifndef.
Anyone know what i'm doing wrong?
Oh yeah I'm using MSVC++ Intro Ed.
#ifndef INTEGER_H
#define INTEGER_H
#endif
the individual files have their own symbols, but im having some problems with that statement now. Correct me if im wrong, but I thought that you use #ifndef to make sure your file is compiled once, right? For some reason, I get "LNK2001: Linker could not resolve external symbol: blah blah blah". And then goes on to list all the Whole number class functions that I had been using. Each of my translation units has an #include for everything it uses, and the only way I can compile is if I lose the #ifndef.
Anyone know what i'm doing wrong?
Oh yeah I'm using MSVC++ Intro Ed.