I wrote: > Hello all, > > I think the following behavior is inconsistent and undesirable: > > scheme@(guile-user)> (list (compile '(define foo 3))) > $1 = (#) > scheme@(guile-user)> (list (primitive-eval '(define foo 3))) > $2 = (#) > > It doesn't really make sense for 'define' to return a value, because it > cannot be used in expression context. AFAICT, the only way to get this > 'return value' is to call 'eval' or 'primitive-eval'. This weirdness > has bitten Paul Smith in his efforts to port his code to Guile 2. > > I think we should change 'define' to always "return" SCM_UNSPECIFIED, at > least in 2.2. We might also consider nipping this in the bud and making > the same change in 2.0.4. The more I think about it, the more convinced I am that this is simply a bug in our Scheme evaluator. Both our compiler and our bootstrap C evaluator returns SCM_UNSPECIFIED for definitions. Therefore, I would like to nip this in the bud and push the following fix for 2.0.4. What do you think? Mark