Re:OO is not Computing, Newer is not More modern
by UK-AL on Monday April 30, 2012 @08:42AM
(#3908960)
That's because without using these things, people can end up accidently shooting themselves foot quite easily. Like accidentally removing the end character from a char* string...
Normal malloc, and dealloc can get stupidly complicated when lots of other objects reference one memory location, which is why these referencing auto pointers come in, with built bounds checking etc
Normal malloc, and dealloc can get stupidly complicated when lots of other objects reference one memory location, which is why these referencing auto pointers come in, with built bounds checking etc
Using those things is defensive programming.