From 5dabbe87ed4e86fa0306fd9ef11e7a7fee2a6ddb Mon Sep 17 00:00:00 2001
From: Leo Tenenbaum <pommicket@gmail.com>
Date: Fri, 8 May 2020 14:38:22 -0400
Subject: got double include to REALLY work

---
 tests/std/io.toc | 9 +++++++++
 1 file changed, 9 insertions(+)

(limited to 'tests/std')

diff --git a/tests/std/io.toc b/tests/std/io.toc
index 9fa7e08..2b9e999 100644
--- a/tests/std/io.toc
+++ b/tests/std/io.toc
@@ -51,3 +51,12 @@ puti ::= fn(x: int) {
 	toc_putchar('\n');
 }
 
+printf ::= #foreign("printf", base.libc) fn (#C &"const char", #C ..) #C int;
+writef ::= fn(x: float) {
+	fmt := "%f\0";
+	printf(&fmt[0], x);
+}
+putf ::= fn(x: float) {
+	writef(x);
+	toc_putchar('\n');
+}
-- 
cgit v1.2.3