In expansion of VALUES, number the local variables to distinguish
authorTaylor R. Campbell <net/mumble/campbell>
Sat, 30 Aug 2008 19:54:37 +0000 (19:54 +0000)
committerTaylor R. Campbell <net/mumble/campbell>
Sat, 30 Aug 2008 19:54:37 +0000 (19:54 +0000)
them visibly.

v7/src/sf/usiexp.scm

index c475256a50d5f3ade21afffde2fd1afcec49514d..9de609c66b9d5c3e21f3ac91913a25773178ac33 100644 (file)
@@ -1,6 +1,6 @@
 #| -*-Scheme-*-
 
-$Id: usiexp.scm,v 4.50 2008/02/13 06:21:07 cph Exp $
+$Id: usiexp.scm,v 4.51 2008/08/30 19:54:37 riastradh Exp $
 
 Copyright (C) 1986, 1987, 1988, 1989, 1990, 1991, 1992, 1993, 1994,
     1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
@@ -359,11 +359,15 @@ USA.
   (if-expanded
    (let ((block (block/make block #t '())))
      (let ((variables
-           (map (lambda (operand)
+           (map (lambda (operand position)
                   operand
                   (variable/make&bind! block
-                                       (string->uninterned-symbol "value")))
-                operands)))
+                                       (string->uninterned-symbol
+                                        (string-append
+                                         "value-"
+                                         (number->string position)))))
+                operands
+                (iota (length operands)))))
        (combination/make
        (and expr (object/scode expr))
        block