aboutsummaryrefslogtreecommitdiff
path: root/src/util.cpp
diff options
context:
space:
mode:
authorAndrew Kelley <andrew@ziglang.org>2019-11-25 16:01:13 -0500
committerGitHub <noreply@github.com>2019-11-25 16:01:13 -0500
commit35d65cceb8aa4360accc0db30b2b1448159e7d26 (patch)
tree34694475702f28f564546d6e61c114507e179b41 /src/util.cpp
parent6b241d7b5d5a9db087c02113b4556d45b0a62e56 (diff)
parenta647a88dfc6cdef66316399f10084b35f738b093 (diff)
downloadzig-35d65cceb8aa4360accc0db30b2b1448159e7d26.tar.gz
zig-35d65cceb8aa4360accc0db30b2b1448159e7d26.zip
Merge pull request #3502 from mikdusan/stage1-mem-diet
unembed ConstExprValue from IrInstruction and intern 1-possible-value types
Diffstat (limited to 'src/util.cpp')
-rw-r--r--src/util.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/util.cpp b/src/util.cpp
index d3dc57e098..56f1de9839 100644
--- a/src/util.cpp
+++ b/src/util.cpp
@@ -121,18 +121,18 @@ SplitIterator memSplit(Slice<uint8_t> buffer, Slice<uint8_t> split_bytes) {
void zig_pretty_print_bytes(FILE *f, double n) {
if (n > 1024.0 * 1024.0 * 1024.0) {
- fprintf(f, "%.02f GiB", n / 1024.0 / 1024.0 / 1024.0);
+ fprintf(f, "%.03f GiB", n / 1024.0 / 1024.0 / 1024.0);
return;
}
if (n > 1024.0 * 1024.0) {
- fprintf(f, "%.02f MiB", n / 1024.0 / 1024.0);
+ fprintf(f, "%.03f MiB", n / 1024.0 / 1024.0);
return;
}
if (n > 1024.0) {
- fprintf(f, "%.02f KiB", n / 1024.0);
+ fprintf(f, "%.03f KiB", n / 1024.0);
return;
}
- fprintf(f, "%.02f bytes", n );
+ fprintf(f, "%.03f bytes", n );
return;
}