Commit Graph

15 Commits

Author SHA1 Message Date
9471b9eae7 test: ensure all tests return a useful status code
These tests were all assumed to execute correctly because CTest is not
capable of parsing the TAP output and instead relies entirely on status
codes.
2017-05-22 13:55:21 +10:00
98dc992473 build: avoid integer length warnings 2017-01-05 19:50:28 +11:00
6d079554a6 format: fix escaped percent before value specifier 2016-12-06 13:37:54 +11:00
fad44bd1f7 format: allow %! specifier for all types
If we allow the %! specifier for all types it greatly simplifies
handling of format strings in templated code, or code with non-trivial
typedefs.
2016-09-27 15:23:33 +10:00
de48f75e96 format: fix transcription of zero values to strings
an iteration condition terminated the write when a value was zero rather
than when all numerals were written. instead, iterate over the remaining
numerals.

fixes printf("%zu", 0u)
2016-08-10 17:38:39 +10:00
c26c687912 format: set ostream precision as if for strings
ostream conversions are converted to strings anyway, so we should treat
them as such earlier in the process.
2016-07-28 16:13:23 +10:00
fad8181842 format: allow undersize integers for conversion 2016-07-28 16:13:23 +10:00
a40e09ed97 format: write c_str as %s by default, support c_str as %p 2016-07-28 14:18:47 +10:00
8cc4c1e82a format: reimplement format rendering
requires literal string arrays, and implements more of the specifier
specification. does not implement 'n' or '$' specifiers. falls back to
snprintf for real arguments.
2016-07-28 13:39:27 +10:00
df9d0ce432 format: add invalid_specifier exception 2016-04-27 16:12:24 +10:00
9248c2f379 format: test invalid specifier with unused specifier
we are using '!' as a specifier now, so don't test invalid specifiers
with this value...
2016-02-03 12:02:56 +11:00
0fd72f0893 format: test case whitespace 2016-01-20 16:39:20 +11:00
c877192cfc format: add test case for char[] 2016-01-20 16:38:54 +11:00
785a9e08f6 tap: remove default format strings 2015-07-21 03:17:20 +10:00
f451e5555e format: add trivial printf wrapper 2015-07-21 01:37:45 +10:00