I have a header file in the solution that defines the class MyTime. It compiles fine.
I also have a MyTime.cpp which implements the member functions. It has #include "MyTime.h", but at compile time it doesn't recognize that MyTime is a class. Is there something more I have to do? Like add a reference to MyTime.h in the project settings -> additional includes?
did you try to learn C++ before posting your shit on /prog/?
Name:
Anonymous2010-10-25 19:33
>>2
Yep, I wrote my own DirectX rendering pipeline in fact. Arrays of pointers and things like that, too. I just can't figure out what I'm missing.
Name:
Anonymous2010-10-25 19:40
Ok, I induce an error in the header, but the first error at compile time is in the cpp. How do I force Visual Studio to examine the header first, THEN compile the cpp?
Name:
Anonymous2010-10-25 20:42
Found out what was wrong.
There was some sort of invisible mac file format character that took up zero spaces hiding after the "ctime" but before the next #include. I knew it was going to be some frustrating 'gotcha' like this, thanks for the help /prog/
Bump, in case anyone is wondering how I got it, I copied the text from a browser window, so the text might not have been just text, but instead might have been some kind of rich text enhanced cross platform friendly blah blah blah. Con't copy/paste from a browser, I guess, is the lesson.