Commit Graph

27 Commits

Author SHA1 Message Date
Bill Currie a487595149 [ruamoko,libr] Begin implementation of __obj_forward
libr supplies an __obj_forward definition that links to a builtin, but
as it is the only def in its object file, it is readily replaceable by
an alternative Ruamoko implementation.

The builtin version currently simply errors out (rather facetiously),
but only as a stub to allow progs to load.
2020-03-09 19:09:08 +09:00
Bill Currie 2ddfe2ef07 [libr] Accept void * for performSelector:withObject:
It's up to the receiver what the object should be.
2020-03-05 15:00:42 +09:00
Bill Currie cdc1f0c5e7 [libr] Treat ruamoko headers as system headers
Now that qfcc actually supports them properly.
2020-03-03 15:24:41 +09:00
Bill Currie 2aaa380098 Fix some uninitialized variable warnings.
While they're false positives (qfcc doesn't know about noreturn), at least
qfcc is doing its job :)
2012-11-21 10:25:29 +09:00
Bill Currie 951bed6206 Allow the retain count to become 0.
With the new retain count scheme, it must reach 0 or double frees won't be
caught.
2012-11-20 14:41:13 +09:00
Bill Currie d5c831b6da Add a little test case for accessing types.
Using ruamoko to access ruamoko type encodings is actually quite pleasant
:)
2012-11-15 13:40:11 +09:00
Bill Currie 9a53531d3b Fix a braino in Object's -init.
I'd forgotten AutoreleasePool doesn't like receiving -retain when I did the
retainCount change, and thus Object's -init was a little too naive.
2012-11-14 20:45:29 +09:00
Bill Currie c96718493a A bit of a cleanup before fixing class type defs.
All internal structs now have "proper" names, and fit the naming convention
(eg, obj_module (like objective-c's types, but obj instead of objc). Some
redundant types got removed (holdovers from before proper struct tag
handling).

Also, it has proven to be unnecessary to build internal classes, so
make_class and make_class_struct are gone, too.
2012-11-12 11:12:33 +09:00
Bill Currie 07e67da838 Add class versions of retain and friends.
As class objects don't have retain counts (they're usually static, even!!),
allowing the instance implementations of retain, release, and autorelease
attempt to modify the non-existant retainCount would be a recipe for severe
headaches. We also don't want the retainCount returning "random" values.
2012-11-08 20:41:56 +09:00
Bill Currie 6b46cde7c8 Move retainCount out of Object.
Going by "standard" Objective-C, retainCount really doesn't belong in
Object itself. The way GNUStep does it is to stash retainCount in memory
just below the object by allocating extra bytes for the count and returning
a pointer just beyond those extra bytes. Now Ruamoko does the same. This
fixes the inconsistencies in structure layouts for Protocol and class
structs between qfcc generated (internal) structs and user visible structs.
2012-11-08 20:24:25 +09:00
Bill Currie 896791b209 Correct the spelling of "int" and clean up the mess. 2011-03-25 16:53:04 +09:00
Bill Currie 7b9d70167f Fix some missed language changes. 2011-03-10 20:51:04 +09:00
Bill Currie ed3f98eab4 qwaq related compile fixes for the new function syntax rules. 2011-02-13 19:07:30 +09:00
Bill Currie d6b10c99aa Most, if not all, of the fixes needed to get qwaq building.
This is pretty much just changing [] to * and moving [N] to the other side
of the variable name.
2011-02-07 22:16:16 +09:00
Bill Currie c38ea0b1bc Correct the spelling of "nil". 2011-01-14 12:07:40 +09:00
Bill Currie 6ebee4ad0e Get the type of Method right.
It's a direct structure rather than a pointer.
2011-01-10 12:25:31 +09:00
Bill Currie 75ec6bf244 Clean out some unnecessary types from the progs engine and clean up the mess.
This is a nasty commit, sorry, but 99% of the commit is interdependent.
2011-01-10 12:25:31 +09:00
Bill Currie e9fea12e47 Must return self in -autorelease 2010-11-24 17:01:19 +09:00
Bill Currie 4518e6af91 First stab at implementing autorelease.
It's probably nowhere near right, but probably ok for now (I need to study
the GNUStep code). I'm unhappy with the menu code hook, but it will have
to do for now.
2010-11-24 17:01:18 +09:00
Bill Currie 3a7ecf9f31 enable obj_sendv
This is an imperfect revision of history.
2004-11-17 21:27:00 +00:00
Bill Currie fb9c3e6125 Object error doesn't return anything... 2004-02-04 00:56:33 +00:00
Bill Currie 7ff9f32706 uncomment some functions that may or may not get implemented 2003-08-23 06:12:10 +00:00
Bill Currie dd9ab1e050 get unsigned mostly working 2003-08-01 21:20:04 +00:00
Jeff Teunissen 7713a539ca Okay, y'all...the Ruamoko root class, Object, has been replaced with another
class with the same name. This will break things. To support it, there are
three new classes, one of which is incomplete (AutoreleasePool). It'll get
finished soonish, but the rest of the class lib will need some updating to
work.
2003-07-29 18:02:03 +00:00
Bill Currie dedb2fa6bf get [super ...] working correctly 2003-05-15 05:58:31 +00:00
Bill Currie dd727edb17 correct the type for obj_verror 2002-10-17 19:33:46 +00:00
Jeff Teunissen 5e1ce57322 Okay, this might or might not work (but it should). It's the beginning of the
Ruamoko standard library overhaul.
2002-08-17 05:27:34 +00:00
Renamed from ruamoko/lib/object.r (Browse further)