* struct and goops questions
@ 2007-12-17 22:42 Andy Wingo
2007-12-27 19:41 ` Neil Jerram
0 siblings, 1 reply; 2+ messages in thread
From: Andy Wingo @ 2007-12-17 22:42 UTC (permalink / raw)
To: guile-devel
Hi all,
I've been looking at structs a bit recently, and goops' use of them. I
have some questions:
(1) Why are struct free functions part of instances and not vtables? It
would seem that they are more appropriate on the vtables (of course
themselves structs), instead of wasting a word per-instance.
(2) Why are structs double cells? It seems that the last two words are
always zero.
(3) Where does the word "entity" come from? It seems to be a term to
describe invokable objects like procedures-with-setters or generics or
something. Quite confusing, and (it seems) completely undocumented.
(4) What, on a class, are the purpose of slots h0 through h7? They seem
to be unused, and garbage (opaque foo). For example, try doing a
(slot-ref <class> 'h0) a few times -- it makes guile segfault for me.
I bet Mikael knows :)
Thanks,
Andy
--
http://wingolog.org/
_______________________________________________
Guile-devel mailing list
Guile-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-devel
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: struct and goops questions
2007-12-17 22:42 struct and goops questions Andy Wingo
@ 2007-12-27 19:41 ` Neil Jerram
0 siblings, 0 replies; 2+ messages in thread
From: Neil Jerram @ 2007-12-27 19:41 UTC (permalink / raw)
To: Andy Wingo; +Cc: guile-devel
Andy Wingo <wingo@pobox.com> writes:
> Hi all,
>
> I've been looking at structs a bit recently, and goops' use of them. I
> have some questions:
>
> (1) Why are struct free functions part of instances and not vtables? It
> would seem that they are more appropriate on the vtables (of course
> themselves structs), instead of wasting a word per-instance.
>
> (2) Why are structs double cells? It seems that the last two words are
> always zero.
>
> (3) Where does the word "entity" come from? It seems to be a term to
> describe invokable objects like procedures-with-setters or generics or
> something. Quite confusing, and (it seems) completely undocumented.
>
> (4) What, on a class, are the purpose of slots h0 through h7? They seem
> to be unused, and garbage (opaque foo). For example, try doing a
> (slot-ref <class> 'h0) a few times -- it makes guile segfault for me.
>
> I bet Mikael knows :)
I bet he knows too. I can't help explain these things, I'm afraid.
Neil
_______________________________________________
Guile-devel mailing list
Guile-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-devel
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2007-12-27 19:41 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-12-17 22:42 struct and goops questions Andy Wingo
2007-12-27 19:41 ` Neil Jerram
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).