Accessor methods only apply to subclasses with their slot
authorAndy Wingo <wingo@pobox.com>
Mon, 26 Jan 2015 16:54:26 +0000 (17:54 +0100)
committerAndy Wingo <wingo@pobox.com>
Mon, 26 Jan 2015 16:57:44 +0000 (17:57 +0100)
commit649ec8d8234ccda55b81930a0cb07d66b4a855c6
tree82abe2f3baff9a84421e0d7c1985d139061d1e7d
parent583a23bf104c84d9617222856e188f3f3af4934d
Accessor methods only apply to subclasses with their slot

* libguile/goops.c (is_accessor_method, scm_compute_applicable_methods):
  Fix regression from 51f66c912078a25ab0380c8fc070abb73d178d98 (2009).
  Accessor methods are added on each subclass on which the slot is
  present; therefore if a subclass doesn't have a method, then the
  methods doesn't apply.  Truly fixes #17355, unlike
  583a23bf104c84d9617222856e188f3f3af4934d.

* module/oop/goops.scm (compute-cmethod, compute-getter-method)
  (compute-setter-method): Revert earlier changes.

* test-suite/tests/goops.test ("accessor slots"): Update for new
  expectations, in agreement with Guile 1.8.
libguile/goops.c
module/oop/goops.scm
test-suite/tests/goops.test