[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: goops proposal: proper struct classes
From: |
Andy Wingo |
Subject: |
Re: goops proposal: proper struct classes |
Date: |
Thu, 05 May 2011 22:39:06 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux) |
On Thu 05 May 2011 22:19, address@hidden (Ludovic Courtès) writes:
>> Vtables *are* classes, on a fundamental level. Bare vtables are not as
>> nice as <class>, but they do describe instances. SCM_CLASS_OF() is
>> SCM_STRUCT_VTABLE().
>
> OK, it would be more elegant.
>
> Can it be achieved without GOOPsifying too much the rest of Guile?
> I mean, creating and accessing raw structs should remain as lightweight as
> currently, so that syntactic-only records à la SRFI-9 can be
> implemented. GOOPS objects are currently heavyweight compared to raw
> structs.
Yes, I think it can. Actually the motivation was to remove the call to
scm_i_define_class_for_vtable from structs, which will allow proper
layering of goops and structs. (You are right to be concerned, I think;
GOOPS is pretty neat to have, and appropriate to some domains, but has
fundamental problems with modularity.)
Cheers,
Andy
--
http://wingolog.org/