GNU bug report logs - #47245
re-defining imported symbol to itself fails

Previous Next

Package: guile;

Reported by: Jan Nieuwenhuizen <janneke <at> gnu.org>

Date: Thu, 18 Mar 2021 16:52:02 UTC

Severity: normal

Full log


View this message in rfc822 format

From: Jan Nieuwenhuizen <janneke <at> gnu.org>
To: 47245 <at> debbugs.gnu.org
Subject: bug#47245: re-defining imported symbol to itself fails
Date: Thu, 18 Mar 2021 17:51:17 +0100
[Message part 1 (text/plain, inline)]
Hi!

Using the attached foo.scm and bar.scm, Guile 2.2 nicely redefines
%foo and %baz:

--8<---------------cut here---------------start------------->8---
$ guild compile -L . -o foo.go foo.scm
wrote `foo.go'
17:48:10 janneke <at> dundal:~/src/guile/master [env]
$ guild compile -L . -o bar.go bar.scm
wrote `bar.go'
17:48:12 janneke <at> dundal:~/src/guile/master [env]
$ guile -C . -c '(use-modules (bar))'
foo: "foo"
baz: "baz"
17:48:16 janneke <at> dundal:~/src/guile/master [env]
$ guile -C . -c '(use-modules (bar))'
foo: "foo"
baz: "baz"
--8<---------------cut here---------------end--------------->8---

Guile-3.0 sets %foo to *unspecified*:

--8<---------------cut here---------------start------------->8---
$ meta/build-env meta/guild compile -L . -o foo.go foo.scm
wrote `foo.go'
17:50:03 janneke <at> dundal:~/src/guile/master [env]
$ meta/build-env guild compile -L . -o bar.go bar.scm
wrote `bar.go'
17:50:10 janneke <at> dundal:~/src/guile/master [env]
$ meta/build-env meta/guile -C . -c '(use-modules (bar))'
foo: #<unspecified>
baz: "baz"
--8<---------------cut here---------------end--------------->8---

Greetings,
Janneke

[foo.scm (application/octet-stream, attachment)]
[bar.scm (application/octet-stream, attachment)]
[Message part 4 (text/plain, inline)]
-- 
Jan Nieuwenhuizen <janneke <at> gnu.org> | GNU LilyPond http://lilypond.org
Freelance IT http://JoyofSource.com | AvatarĀ® http://AvatarAcademy.com

This bug report was last modified 4 years and 87 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.