Re-use the vtable "size" field for GOOPS nfields
authorAndy Wingo <wingo@pobox.com>
Sun, 11 Jan 2015 15:36:45 +0000 (16:36 +0100)
committerAndy Wingo <wingo@pobox.com>
Fri, 23 Jan 2015 15:16:02 +0000 (16:16 +0100)
commit92928b8619d2711e9e05b94831a479525ba9aede
tree21978fd82a49db5db06ab970a62107a2901ea9f2
parent4702cbeb3780d0c81076bae0723a1fd544576471
Re-use the vtable "size" field for GOOPS nfields

* module/oop/goops.scm (fold-<class>-slots): The first "reserved" slot
  is actually for instance sizes, used by the "simple struct"
  mechanism.  Reuse this field for GOOPS's "nfields".
  (make-standard-class, <class>, initialize): Adapt order of field
  initializations.

* libguile/goops.h (SCM_CLASS_CLASS_LAYOUT, SCM_N_CLASS_SLOTS)
* libguile/goops.c (scm_sys_allocate_instance): Adapt.
libguile/goops.c
libguile/goops.h
module/oop/goops.scm