Skip to main content
gamedev.net
🔒 Locked

Something f'd up

Started by Ganoosh_ Sep 3, 2006 at 8:42 PM 4 replies 950+ views
Original Post
Ganoosh_
Ganoosh_
Apparently my compiler decided to get rid of the default constructor rule or something. Now any call to an objects default constructor (no paramaters) where I haven't defined it, it saying it doesn't exist. Of course it exists, it always exists where you overwrite it or not. So how do I fix this without having to write 5000 useless constructors? Sorry if I sound rude at all, I'm pretty damn pissed about this. Oh by the way: C++, Dev-C++ on windows
Deyja
Deyja
It exists if you don't write it and don't write any other constructor either.

No, your compiler didn't just 'decide they didn't exist anymore', you made a mistake.
Ganoosh_
Ganoosh_
Hmmm, didn't know that, but I guess it just caught on, cuz it's compiled like that 100's of times already. Maybe something triggered it. Thanks, I'll have to go fix it now
Sirisian
Sirisian
yah one missing '{', '}', '(', ')' can affect other lines and spread creating hundreds of other errors. Don't forget if all else fails, proccess of elimination always works.
dbzprogrammer
dbzprogrammer
Quote:
Original post by Deyja
It exists if you don't write it and don't write any other constructor either.

No, your compiler didn't just 'decide they didn't exist anymore', you made a mistake.


My compiler lets me get away with this. (MSVC++ 6.0) Then again, the compiler is supposedly buggy. But yes, when messing in Dev C++, if you declare a parameter constructor, you need to declare one without params too.
We should do this the Microsoft way: "WAHOOOO!!! IT COMPILES! SHIP IT!"
Ganoosh_
Ganoosh_
Thanks for the advice, what I don't get, is I've had it like this for at least a month and it's been compiling no problem. Then all of a sudden it catches it.

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.