From ddda118314ab5ed4a21522bd2f3806d82f40031a Mon Sep 17 00:00:00 2001 From: Elijah Cohen Date: Tue, 24 Dec 2024 17:14:44 -0800 Subject: [PATCH] (not (< n n)) sigh... --- src/builtins/arithmetic.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/builtins/arithmetic.c b/src/builtins/arithmetic.c index c13a0dc..1fb7f60 100644 --- a/src/builtins/arithmetic.c +++ b/src/builtins/arithmetic.c @@ -152,7 +152,7 @@ Sexpr* a_mod(Sexpr* b, Sexpr* rest, Sexpr* env) { sexpr_free(b); sexpr_free(i); sexpr_free(j); - return cons(m > n ? from_nil(): from_t(), rest); + return cons(m < n ? from_t(): from_nil(), rest); } Sexpr* a_lt(Sexpr* b, Sexpr* rest, Sexpr* env) { @@ -176,7 +176,7 @@ Sexpr* a_lt(Sexpr* b, Sexpr* rest, Sexpr* env) { sexpr_free(b); sexpr_free(i); sexpr_free(j); - return cons(m < n ? from_nil() : from_t(), rest); + return cons(m > n ? from_t() : from_nil(), rest); } -- 2.39.2