thinking about it, I probably wrote nonsense yesterday:
> If you have a function 'rankClass' which returns the depth where a class
> in the hierarchy is located
> (de rankClass (Cls)
The depth does not matter, right?
Instead, the top-level base classes must be compared (you used
'subclass?' respectively 'isa' after all). And, it looks like 'NIL's
must be greater than anything else.
So a function that converts a list like
This could be done simply with
(not L) # Make 'T' from 'NIL'
(prog # Else top level class
(while (type (last L))
(setq L @) )
(last L) ) ) )
(car Lst) )
This assumes that 'Table' is of the form
(((+Asteroid) (+Asteroid)) (X Y) (prinl "aa"))
so that '(car Lst)' is '((+Asteroid) (+Asteroid))'.
What do you think?