diff options
Diffstat (limited to 'tests/arr')
-rw-r--r-- | tests/arr/arr.toc | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/tests/arr/arr.toc b/tests/arr/arr.toc index f7c6707..a682283 100644 --- a/tests/arr/arr.toc +++ b/tests/arr/arr.toc @@ -1,9 +1,16 @@ puti ::= fn(x: int) { - #C("extern int printf(const char *fmt, ...)"); +//tcc's giving me "incompatible types for redefinition of 'printf'" for some reason (even though the declarations have the exact same type) + #C("#ifndef __TINYC__ +extern int printf(const char *fmt, ...); +#endif +"); #C("printf(\"%ld\\n\", (long)x)"); }; putf ::= fn(x: float) { - #C("extern int printf(const char *fmt, ...)"); + #C("#ifndef __TINYC__ +extern int printf(const char *fmt, ...); +#endif +"); #C("printf(\"%f\\n\", (double)x)"); }; |