shithub: femtolisp

Download patch

ref: db405e1a4af5f93671d269d65fa716b8dbdcbdf0
parent: 808b3dcb532487bd6bc7ec428aa9171dd901258d
author: Sigrid Solveig Haflínudóttir <sigrid@ftrv.se>
date: Wed Dec 4 14:36:54 EST 2024

apply_cl: tail: int → bool

--- a/flisp.c
+++ b/flisp.c
@@ -856,11 +856,10 @@
 apply_cl(uint32_t nargs)
 {
 	uint32_t top_frame = FL(curr_frame);
-	// frame variables
 	uint32_t n, bp;
 	const uint8_t *ip;
 	fixnum_t s, hi;
-	int tail, x;
+	bool tail;
 
 	// temporary variables (not necessary to preserve across calls)
 	size_t isz;
@@ -869,6 +868,7 @@
 	cons_t *c;
 	value_t *pv;
 	value_t func, v, e;
+	int x;
 
 	n = 0;
 	v = 0;
@@ -1022,19 +1022,19 @@
 			NEXT_OP;
 
 		OP(OP_TCALLL)
-			tail = 1;
+			tail = true;
 			if(0){
 		OP(OP_CALLL)
-				tail = 0;
+				tail = false;
 			}
 			n = GET_INT32(ip);
 			ip += 4;
 			if(0){
 		OP(OP_TCALL)
-				tail = 1;
+				tail = true;
 				if(0){
 		OP(OP_CALL)
-					tail = 0;
+					tail = false;
 				}
 				n = *ip++;  // nargs
 			}
@@ -1497,10 +1497,10 @@
 			NEXT_OP;
 
 		OP(OP_TAPPLY)
-			tail = 1;
+			tail = true;
 			if(0){
 		OP(OP_APPLY)
-				tail = 0;
+				tail = false;
 			}
 			n = *ip++;
 		apply_apply: