|
-
May 28th, 2009, 04:10 PM
#13
Re: pointers--when to use them
That particular example is probably a bad idea.
However, good C++ programmers will always prefer references over pointers when all else is equal, since they're, indeed, harder to **** up.
That's what it always comes down to at the end of the day. Write your code in whatever style makes it hardest to do something stupid, and easiest to see at a glance what's going on.
Last edited by Lindley; May 28th, 2009 at 04:13 PM.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|