(val: number | null | undefined)
| 129 | // Formatting helpers |
| 130 | |
| 131 | export function floatMaxString(val: number | null | undefined): string { |
| 132 | if (val == null) return '' |
| 133 | if (val === UNSET_DOUBLE) return '' |
| 134 | // Match Python's f"{val:.8f}".rstrip("0").rstrip(".").rstrip(",") |
| 135 | const s = val.toFixed(8) |
| 136 | return s.replace(/0+$/, '').replace(/\.$/, '').replace(/,$/, '') |
| 137 | } |
| 138 | |
| 139 | export function longMaxString(val: bigint): string { |
| 140 | return val !== UNSET_LONG ? String(val) : '' |
nothing calls this directly
no outgoing calls
no test coverage detected