From 5420cc083d08a4c0faffbcf3ec1deecf05b6265d Mon Sep 17 00:00:00 2001 From: gingerBill Date: Wed, 12 May 2021 23:26:21 +0100 Subject: [PATCH] Implement #807 --- core/fmt/fmt.odin | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/core/fmt/fmt.odin b/core/fmt/fmt.odin index f9c386ffb..3b3716a15 100644 --- a/core/fmt/fmt.odin +++ b/core/fmt/fmt.odin @@ -641,9 +641,9 @@ fmt_write_padding :: proc(fi: ^Info, width: int) { return; } - pad_byte: byte = '0'; - if fi.space { - pad_byte = ' '; + pad_byte: byte = ' '; + if !fi.space { + pad_byte = '0'; } for i := 0; i < width; i += 1 {