aboutsummaryrefslogtreecommitdiffhomepage
path: root/testdata/cgo/out.txt
diff options
context:
space:
mode:
authorAyke van Laethem <[email protected]>2024-01-27 12:43:45 +0100
committerRon Evans <[email protected]>2024-08-10 23:46:58 -0700
commit2eb39785fe9d0188e444fd1eb29f1ce2c7a89419 (patch)
treed44479528d48558526a788d0d519b37f5735837e /testdata/cgo/out.txt
parent3021e16bbf138ef48d840604e330049def61329a (diff)
downloadtinygo-2eb39785fe9d0188e444fd1eb29f1ce2c7a89419.tar.gz
tinygo-2eb39785fe9d0188e444fd1eb29f1ce2c7a89419.zip
cgo: add support for printf
The C printf function is sometimes needed for C files included using CGo. This commit makes sure they're available on all systems where CGo is fully supported (that is, everywhere except on AVR). For baremetal systems using picolibc, I've picked the integer-only version of printf to save on flash size. We might want to consider providing a way to pick the floating point version instead, if needed.
Diffstat (limited to 'testdata/cgo/out.txt')
-rw-r--r--testdata/cgo/out.txt1
1 files changed, 1 insertions, 0 deletions
diff --git a/testdata/cgo/out.txt b/testdata/cgo/out.txt
index ae92c87a7..4ea45d864 100644
--- a/testdata/cgo/out.txt
+++ b/testdata/cgo/out.txt
@@ -77,3 +77,4 @@ copied string: foobar
CGo sqrt(3): +1.732051e+000
C sqrt(3): +1.732051e+000
line written using C puts
+line written using C printf with value=-21