shithub: sl

Download patch

ref: b980c33f7efe5e173e196b6c47de5c99b705b017
parent: 53d21f2ed4740641eb50d443e43615fe8d2130b3
author: Sigrid Solveig Haflínudóttir <sigrid@ftrv.se>
date: Tue Apr 8 01:06:54 EDT 2025

print: rune arrays as arrays rather than strings

--- a/src/print.c
+++ b/src/print.c
@@ -819,20 +819,13 @@
 					outc(f, '"');
 				}
 				return;
-			}else if(eltype == sl_runesym){
+			}else if(eltype == sl_runesym && sl.print_princ){
 				char buf[UTFmax+1];
-				if(!sl.print_princ)
-					outc(f, '"');
 				for(i = 0; i < cnt; i++, data = (char*)data + elsize){
 					n = runetochar(buf, (Rune*)data);
 					buf[n] = 0;
-					if(!sl.print_princ)
-						print_str(f, buf, n);
-					else
-						outsn(f, buf, n);
+					outsn(f, buf, n);
 				}
-				if(!sl.print_princ)
-					outc(f, '"');
 				return;
 			}
 			if(!weak){
--