fix invocation of duplicate handlers for merge-generics
authorAndy Wingo <wingo@pobox.com>
Thu, 7 Jul 2011 10:21:48 +0000 (12:21 +0200)
committerAndy Wingo <wingo@pobox.com>
Thu, 7 Jul 2011 11:02:45 +0000 (13:02 +0200)
commit319dd08936ec2d14272f68c16f778c411ed4b505
treeac3151333544cb24e9b90e1173179b5e247df3cc
parenta8c10aa131eb5dd104f134d2ed66afe225fea8e6
fix invocation of duplicate handlers for merge-generics

* libguile/modules.c (resolve_duplicate_binding): Fix unbound -> #f
  conversion for the imported bindings.  Pass the existing entry in the
  import obarray as the resolved var (7th arg), and properly pass #f as
  the value (8th arg) if there is no such binding.  Fixes
  merge-generics; before, the <boolean> type test (indicating no
  previous value) was not being triggered.  This bug has been present
  since 2007 at least, though it was not in 1.8.

* test-suite/tests/modules.test ("duplicate bindings"): Add a test that
  the var and val are both #f.  These types are used by GOOPS.
libguile/modules.c
test-suite/tests/modules.test