pouët.net

Go to bottom

derived class deletion

category: code [glöplog]
Quote:
Valgrind? Is that what Linux programmers do instead of having a HTTP server [...]

C++? Is that what sceners use instead of a properly designed language?
added on the 2010-08-01 21:15:09 by blala blala
Oh, fuck off.
added on the 2010-08-01 21:22:30 by trc_wm trc_wm
Gargaj, really, amigados is *that* bad? glad I'm not coding for it :)

Agree with blabla.. give me either C or some real high-level language. Not an abomination like C++
added on the 2010-08-01 22:40:16 by _-_-__ _-_-__
Kravitz/Inf once told me that C++'s attempt at creating object orientation on top of C resembled glueing legs to an earthworm in order to create a millipede. It might be a quote from somewhere else, but I think it's a good point.

C++ sucks, but it's sadly often the only real option. I prefer vanilla C when I can get away with it, though.
added on the 2010-08-02 00:38:36 by kusma kusma
C++ isn't bad, it's just not perfect. But the fact that it's "often the only real option" says a lot, given the number of alternatives. At the end of the day, C++ produces leaner, meaner, and more maintainable code than other languages, precisely because of all those "poor" design choices that people criticise it for. And many of its supposed shortcomings are in fact not, like the lack of GC (GC is great in theory, but in reality it makes resource management a lot harder).
added on the 2010-08-02 02:02:36 by doomdoom doomdoom
I'm running Linux, I'm not sure if I can let the OS act as the deallocator.
I'll have to check if there's something like ExitProcess.
Thanks all for the input.
added on the 2010-08-02 03:11:10 by duffman duffman
Quote:
I'm running Linux, I'm not sure if I can let the OS act as the deallocator.

Yes you can. I don't think there's any OS left outside of extremely resource-constrained embedded systems that doesn't do this.
Quote:
I'll have to check if there's something like ExitProcess.

It's called exit(). Like, the one from stdlib.h. Duh.
added on the 2010-08-02 07:23:46 by ryg ryg
#define exit cleanUpMyShitBitchAndLeave
added on the 2010-08-02 11:09:42 by raer raer
#define exit() return
added on the 2010-08-02 11:16:46 by doomdoom doomdoom
Code: template<void (*F)()> struct EXIT{static void EXIT(){F();}}; int main() { EXIT<exit>::EXIT(); }
added on the 2010-08-03 23:19:59 by rmeht rmeht
what, no try-catch?
added on the 2010-08-04 01:02:53 by Gargaj Gargaj

login

Go to top