News for hackers. Stuff that matters.
Re:Mac Apps That Use Garbage Collection Must Move to ARC by coliveira on Sunday February 22, 2015 @09:56PM (#9092307)
C++ is a language that allows any kind of memory manipulation, if you really want (or need) to do it. So your example doesn't prove anything about the adequacy of shared_ptr in particular.
Re:Mac Apps That Use Garbage Collection Must Move to ARC by pjmlp on Monday February 23, 2015 @02:27AM (#9093084)
My point was that if a language does RC via library types that exposure the pointer that they own, there is no safety guarantee about memory safety.

It is impossible to prove that all memory access to a given address are done via the RC wrapper object, specially in the presence of third party libraries in binary form.

Sadly due to its C compatibility, there is no way around this in C++.

This is mostly a problem in large projects with various skill levels across team members, having high attrition levels.

Re:Mac Apps That Use Garbage Collection Must Move to ARC by coliveira on Monday February 23, 2015 @10:10PM (#9098485)
As I mentioned above, the goal of C++ is not to provide memory safety guarantees. What it provides is a mechanism for RC implementation. You're free to use or misuse it if you want. It will work only for those objects that you think should be managed with RC, nothing more or less.