[gimp] R5RS compatability fix for append by Doug Currie. (SourceForge bug #3400202) Append with one argume



commit 5d3be5be3c1b66d44f7d7ae919db9c1768a8c1b9
Author: Kevin Cozens <kcozens svn gnome org>
Date:   Mon Aug 29 16:08:47 2011 -0400

    R5RS compatability fix for append by Doug Currie.  (SourceForge bug #3400202)
    Append with one argument should return the argument but not as a list.

 plug-ins/script-fu/tinyscheme/scheme.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/plug-ins/script-fu/tinyscheme/scheme.c b/plug-ins/script-fu/tinyscheme/scheme.c
index 9dcab5e..4a85f6d 100644
--- a/plug-ins/script-fu/tinyscheme/scheme.c
+++ b/plug-ins/script-fu/tinyscheme/scheme.c
@@ -495,7 +495,7 @@ static num num_rem(num a, num b) {
  e1=num_ivalue(a);
  e2=num_ivalue(b);
  res=e1%e2;
- /* modulo should have same sign as second operand */
+ /* remainder should have same sign as second operand */
  if (res > 0) {
      if (e1 < 0) {
         res -= labs(e2);
@@ -3985,7 +3985,7 @@ static pointer opexe_4(scheme *sc, enum scheme_opcodes op) {
           }
           x=car(sc->args);
           if(cdr(sc->args)==sc->NIL) {
-            s_return(sc,sc->args);
+            s_return(sc,x);
           }
           for (y = cdr(sc->args); y != sc->NIL; y = cdr(y)) {
                x=append(sc,x,car(y));



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