Expand description
Shared number formatting for emission.
format_number renders a Workshop number the way the pinned oracle
does for computed values: integers print without a decimal point, and
non-integers print the shortest round-trip representation truncated to 16
significant digits (OverPy behavior; evidence: the pinned oracle
snapshots). Literal source spellings (e.g. 0.0, 5.0) are preserved by
the frontends’ number nodes and take precedence over this formatter.
Functions§
- format_
number - Format a float like the reference frontend: integers print without a decimal point, and non-integers print the shortest round-trip representation truncated to 16 significant digits (OverPy behavior; evidence: the pinned oracle snapshots).