summaryrefslogtreecommitdiffstats
path: root/share
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2021-06-14 07:06:05 -0700
committerKaz Kylheku <kaz@kylheku.com>2021-06-14 07:06:05 -0700
commita0834f3bd8a3beca14501190b46062484b90f555 (patch)
treee874d2b981ecda584a30f58e2b1e2126af0f53d3 /share
parent86d04654a747f537c43e464adb227118d11bfd10 (diff)
downloadtxr-a0834f3bd8a3beca14501190b46062484b90f555.tar.gz
txr-a0834f3bd8a3beca14501190b46062484b90f555.tar.bz2
txr-a0834f3bd8a3beca14501190b46062484b90f555.zip
format: revise numeric handling.
There are a number of issues, such as left adjustment not working and such. This needs a better treatment from the requirements level, through to a set of test cases. * stream.c (max, min): Macros macros added, in their usual form. (vformat_num): Implement new rules which suppress the zero and space characters used in place of a sign if they overflow the field width. (formatv): Clamp integer precision field to width - 1 for integers, for consistency with floating-point handling. For floating-point values under ~a and ~s, do not force the second stage precision to width - 1; only clamp it if it is greater. * format.tl: Numerous new tests. * txr.1: Significant redocumenting of this area. The handling of numbers is described as a two stage process, clarifying the changing role of "precision" in the two stages.
Diffstat (limited to 'share')
0 files changed, 0 insertions, 0 deletions