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

C++ pointer vs. non-pointer

Name: Anonymous 2010-05-22 19:54

Sup /prog/

C++, if I make my own class, lets just say class cShitHead

cShitHead dave * new cShitHead( "dave" );
dave->PrintName();

or

cShitHead dave( "dave" );
dave.PrintName();

I myself like the pointer notation better. However, which one is more efficient and better on memory? and why?

Name: Anonymous 2010-05-22 21:04

>>13
At that point I hit you over the head with a blunt object and interrogate you until I find out what it is you are actually trying to do. What you are doing now is the equivalent of saying that we should all use Assembly, because every last bit is precious. It's 2010, memory is plentiful. Every last bit is not precious.

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