No. I think cleaning up, manually or automatically, after objects go out of scope is not the same as garbage collecting. "Garbage" here implies objects that linger beyond their usage scope, from construction to destruction, and now have become garbage taking up memory that can only be reclaimed by an extraneous routine, ie the GC.
C++ has wider options managing resource acquisition. Scope is just one case.
https://en.wikipedia.org/wiki/Smart_pointer#C.2B.2B_smart_po...
Re:Garbage Collection is Wrong
by plorkyeran on Thursday February 27, 2014 @04:45PM
(#7315346)
Garbage collection is not a synonym for automatic memory management.
The way I understand it, no garbage collection means you take care of cleaning after yourself, whereas garbage collectors do it for you. It sounds like what he calls resource acquisition.