🔒 Locked
Dev-C++
Advertisement
Original Post
Whats up with Dev-C++ not wanting to compile classes!?!?! I even downloaded the tutorial off of the Game Tutorials website that was made for Dev-C++ and it still wouldn''t compile without errors! Anyone know of a better freeware C++ compiler?
Dev-C++ isn''t a compiler, it''s an IDE. There is something YOU are doing wrong, basically, to not make it compile. It uses the MinGW compiler (minimalist gnu for win32). The compiler is excellent. You are wrong.
"Few creatures of the night have captured our imagination like vampires..." Godsmack: Vampires.
(c) 2003 DigiAC - My solo company in progress.
"Few creatures of the night have captured our imagination like vampires..." Godsmack: Vampires.
(c) 2003 DigiAC - My solo company in progress.
did you check you put a semi colon on the end of the class like this:
Its easy to overlook sometimes.
-J
class myclass
{
public:
int var;
}; //this semicolon.
Its easy to overlook sometimes.
-J
And also, if you want help, it helps to actually tell us the errors you are receiving, as well as the portion of code that you receive the error on. Bad mouthing a perfectly good (and perfectly free) IDE/compiler bundle without backing yourself up (in the Lounge, nonetheless), is no way to go about fixing your problems.
Plently of people have gotten Dev-C++ to work for them flawlessly (myself included).
|.dev-c++.|.the gimp.|.seti@home.|.dbpoweramp.|.torn.|.=w=.|
Plently of people have gotten Dev-C++ to work for them flawlessly (myself included).
|.dev-c++.|.the gimp.|.seti@home.|.dbpoweramp.|.torn.|.=w=.|
Yes, remember the semicolon, I forget it many times.
The new versions of Dev-C++ did not work for me. That is why I got Visual Studio .NET. Can you post up the source code?
If there is nothing wrong with the source code, you can try downloading an older version of MinGW (Or Dev-C++ with an older version of MinGW in it).
What you can also do is download Borland (I don''t remeber how to spell it, I think its pretty close...) and set it up so Dev-C++ compiles with Borland.

E-mail:wiseelben@wiseelben.com
AIM: WiseElben
ICQ: 299127026
[edited by - GameDev Staff on September 27, 1989 9X:58:97 XMS] For violating Article 43 Page 456 Paragraph 251 Line .042
The new versions of Dev-C++ did not work for me. That is why I got Visual Studio .NET. Can you post up the source code?
If there is nothing wrong with the source code, you can try downloading an older version of MinGW (Or Dev-C++ with an older version of MinGW in it).
What you can also do is download Borland (I don''t remeber how to spell it, I think its pretty close...) and set it up so Dev-C++ compiles with Borland.
E-mail:wiseelben@wiseelben.com
AIM: WiseElben
ICQ: 299127026
[edited by - GameDev Staff on September 27, 1989 9X:58:97 XMS] For violating Article 43 Page 456 Paragraph 251 Line .042
Here it is...and the error...
1) 14 C:\Dev-Cpp\My Projects\Adventure2\monster.h
parse error before
There could just be something wrong with the my "Class"...im still a newbie so im not sure.
class Monster()
{
string name;
int expe;
int hitpoints;
public:
Monster(string mName,int exp,int hp);
~Monster();
int Attack();
int Die(int e);
};
1) 14 C:\Dev-Cpp\My Projects\Adventure2\monster.h
parse error before
public''
2) 8 C:\Dev-Cpp\My Projects\Adventure2\monster.h
parse error before )'' tokenThere could just be something wrong with the my "Class"...im still a newbie so im not sure.
quote:
Original post by DarkWhoppy
There could just be something wrong with the my "Class"...im still a newbie so im not sure.
Where did you learn to program? You either need a better book (or a book in the first place) or a good teacher. Now you know not to blame the compiler, especially when you make bad mistakes.
Next time, if you are having trouble with code relating to a class, perhaps you should search the web for some information about writing C++ classes.
Actually I downloaded the tutorial on classes from Game Tutorials and that wouldn't compile either. So I thought maybe it was the compiler... And yes I have a book...I've read it already and need to buy a new one because this one is just the basics of C++.
[edited by - DarkWhoppy on August 5, 2003 11:57:09 PM]
[edited by - DarkWhoppy on August 5, 2003 11:57:09 PM]
Topic Locked
This topic has been locked by a moderator. New replies are not allowed.
Sign in to reply to this topic.
Advertisement