summaryrefslogtreecommitdiff
path: root/module/system/foreign-object.scm
AgeCommit message (Collapse)AuthorFilesLines
2024-05-17make-foreign-object-type: add #:super to provide superclassesRob Browning1-4/+5
* module/system/foreign-object.scm (make-foreign-object-type): allow specification of superclasses via #:super.
2015-02-06Add #:static-slot-allocation?Andy Wingo1-0/+2
* libguile/goops.h (SCM_VTABLE_FLAG_GOOPS_STATIC): Reserve the fourth GOOPS flag to indicate that a class has static slot allocation. * libguile/goops.c (scm_init_goops_builtins): Define vtable-flag-goops-static for goops.scm. * module/oop/goops.scm (class-has-statically-allocated-slots?): New helper. (build-slots-list): Instead of the ad-hoc checks for <class> or <slot>, use the new helper. (initialize): Accept #:static-slot-allocation? keyword. * module/system/foreign-object.scm (make-foreign-object-type): Declare foreign object classes as having static slot allocation. * test-suite/tests/goops.test ("static slot allocation"): Add tests.
2015-02-06Fix foreign objects for getter method changeAndy Wingo1-21/+22
* module/system/foreign-object.scm: Fix getters after change to make <accessor-method> instances only apply to their precise specializer types.
2015-01-23Fix foreign objects for removal of getters-n-settersAndy Wingo1-2/+2
* module/system/foreign-object.scm (getter-method): Fix for removal of getters-n-setters property.
2014-04-28New foreign object facility, to replace SMOBsAndy Wingo1-0/+88
* libguile/foreign-object.c: * libguile/foreign-object.h: * module/system/foreign-object.scm: * test-suite/standalone/test-foreign-object-c.c: * test-suite/standalone/test-foreign-object-scm: New files. * test-suite/standalone/Makefile.am: * module/Makefile.am: * libguile/Makefile.am: Add new files. * libguile.h: Add foreign-object.h. * libguile/init.c (scm_i_init_guile): Call scm_register_foreign_object.