1
0
mirror of https://github.com/cc65/cc65.git synced 2024-06-26 05:29:30 +00:00
cc65/testcode
Oliver Schmidt d242afdf7e Added sprintf() test contributed by Ullrich von Bassewitz.
Comment from the author:

Some may remember that there was a problem with printf reported a long time
ago. I got curious and over the weekend, I wrote a program to test printf. Or
better: The underlying formatting code, which is used for the whole printf()
family of functions including cprintf and sprintf.

The result is what made me say "oops": The program tests 377 different
conversions. The cc65 printf implementation fails in 144 cases. In 31 of these
cases, it fails so badly that it outputs screens of garbage, or even crashes
the machine, so I had to disable these tests to proceed.

Please note that you can compile the code with gcc for x86, but it will show
failures. This is because the expected results are hardcoded and the integer
sizes of gcc are different, so the conversion results won't match the ones
expected in the code.
2013-07-27 17:21:07 +02:00
..
assembler Test file for illegal 6502 opcodes 2005-01-09 19:07:45 +00:00
compiler Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
grc Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
lib Added sprintf() test contributed by Ullrich von Bassewitz. 2013-07-27 17:21:07 +02:00