Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon.

Pages: 1-

Class not recognized

Name: Anonymous 2010-10-25 17:58

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?

Name: Anonymous 2010-10-25 18:44

did you try to learn C++ before posting your shit on /prog/?

Name: Anonymous 2010-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: Anonymous 2010-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: Anonymous 2010-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/

//#include "ctime"
#include "MyTime.h"

Name: Anonymous 2010-10-25 22:42

Less of this.

Name: Anonymous 2010-10-26 0:31

>>6
Less of ``less of this''

Name: Anonymous 2010-10-26 4:23

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.

Name: Anonymous 2010-10-26 6:11

Bump, in case anyone is wondering how I got it,
This is not how /prog/ works.

Name: Anonymous 2010-10-26 6:21

>>9
Bump, in case >>9 is a flaming faggot.

Name: Anonymous 2010-10-26 6:26

This thread has ended peacefully.
Class dismissed.

Name: Anonymous 2010-10-26 6:33

>>10
Did you mean ``because''? Using the wrong word could be easily explained by your apparent brain damage.

Name: Anonymous 2010-10-26 11:34

Bump, because >>9,12 is a flaming faggot.

Name: Anonymous 2011-02-04 12:19

Don't change these.
Name: Email:
Entire Thread Thread List