[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

question about values

From: Massimiliano Gubinelli
Subject: question about values
Date: Wed, 18 Mar 2020 00:50:43 +0100

Hi all,

 I do not understand what happens here:

mgubi@Ulrike guile3-usr % guile
guile> (version)
guile> (call-with-values (lambda () (let ((a (values "a" "b" "c"))) a)) (lambda 
body body))
("a" "b" "c")

mgubi@Ulrike guile3-usr % bin/guile
GNU Guile 3.0.1
Copyright (C) 1995-2020 Free Software Foundation, Inc.

Guile comes with ABSOLUTELY NO WARRANTY; for details type `,show w'.
This program is free software, and you are welcome to redistribute it
under certain conditions; type `,show c' for details.

Enter `,help' for help.
scheme@(guile-user)> (version)
$1 = "3.0.1"
scheme@(guile-user)> (call-with-values (lambda () (let ((a (values "a" "b" 
"c"))) a)) (lambda body body))
$2 = ("a")

Why the two versions of Guile behave differently? Which is the "correct" 
behaviour, and in case: how to propagate multiple results safely?



reply via email to

[Prev in Thread] Current Thread [Next in Thread]