15 Commits (9206f48bce61478c6fb845a0e30d7dd68930175e)

Author SHA1 Message Date
David Chisnall b3f7b1bac3 Remove Boehm GC support code.
This removes all support for GC mode.

This was deprecated by Apple in OS X 10.8 (2012) and never supported in
iOS.  Very little code ever tried to use it with this runtime.

It's gone from the build system already.
3 years ago
theraven f3d2b7034c Small object + ARC tweaks. 15 years ago
theraven 2288ff54e3 Don't try to enable GC in ARC mode. 15 years ago
theraven 7b6ba21ce5 Small bug fixes:
- Don't call C++ constructors if they don't exist.
- Don't check the owner of retain / release methods if they are not implemented.
- Add arc.m as a file to ignore when checking for GC compatibility.
15 years ago
theraven d1199844cb Lock the GC mode once something has queried it. All of the GNUstep code that
does run-time detection of whether to use GC calls objc_collecting_enabled()
(sometimes indirectly, via NSGarbageCollector) to see if we're in GC mode.
After any of these calls, it is not safe to switch modes.
15 years ago
theraven fe5d1b892a Tweak GC check, make sure GC_init() is called even when ObjC code isn't using GC (stuff internal to the runtime may be) 15 years ago
theraven 3508ab6ccf Fixed ABI compatibility test. 15 years ago
theraven e05c9c2ff5 More GC fixes 15 years ago
theraven ae4eea1597 Some bug fixes for GC mode. 15 years ago
theraven 22c20eb930 Removed spurious debugging line. Removed left-over check that stopped GC_Optional modules from enabling the GC. 15 years ago
theraven 444688895a Updated Makefile to compile correctly again.
Added a really ugly hack so that the ABI versions of the three .m files are not checked.  This will (hopefully!) prevent the GC being enabled when libobjc is loaded after being compiled with -fobjc-gc.
15 years ago
theraven 929f8f95b4 Improved a few GC functions.
Added objc-auto.h header, providing (documented) public interfaces to this
functionality.
15 years ago
theraven ad16172625 First pass at implementing Apple-compatible GC using Boehm. Still needs some tidying, but the following work:
- __strong pointers, preventing objects from being freed

_ __weak pointers are automatically freed when the last remaining __strong pointer goes away

- objc_gc_{retain,release}_np() functions, which can be used to implement CFRetain() and CFRelease() (adds an reference count - the object will not be collected until after its last retain is gone.
15 years ago
theraven 6c7cf4a5a6 Add visibility attributes on all internal functions so that we aren't ever exporting them outside of libobjc. 15 years ago
theraven 7c72069fd9 Rewrote ABI compatibility testing. Makes it easier to define new, incompatible ABIs in future without breaking everything. 16 years ago