shithub: femtolisp

Download patch

ref: 5bedf304eecaf53564599861a4335e93ec988b7b
parent: 20488fc4915662e0ec50bb8c4ebc2609d6e110b4
author: Sigrid Solveig Haflínudóttir <sigrid@ftrv.se>
date: Fri Nov 15 20:04:13 EST 2024

fl_any_arith: fix wrong function used (mpnew → vtomp)

--- a/fl_arith_any.inc
+++ b/fl_arith_any.inc
@@ -81,14 +81,8 @@
 	i++;
 	if(Maccum == nil)
 		Maccum = vtomp(Saccum, nil);
-	if(m == nil){
-		if(u64 != ACCUM_DEFAULT)
-			m = uvtomp(u64, nil);
-		else if(x != ACCUM_DEFAULT)
-			m = vtomp(x, nil);
-		else
-			m = mpnew(ACCUM_DEFAULT);
-	}
+	if(m == nil)
+		m = u64 != ACCUM_DEFAULT ? uvtomp(u64, nil) : vtomp(x, nil);
 
 	MP_OP(Maccum, m, Maccum);