aboutsummaryrefslogtreecommitdiff
path: root/lib/std/crypto
diff options
context:
space:
mode:
authorRyan Liptak <squeek502@hotmail.com>2020-01-09 01:56:38 -0800
committerAndrew Kelley <andrew@ziglang.org>2020-01-09 13:36:44 -0500
commit834218d789430ac238e5ef4fa99cfe4bcf006f2d (patch)
tree6a43ac11524812625dba225dde6a091bcf2b0b2d /lib/std/crypto
parentd7333d8798a929312ceb897007e7bb6a8b2999ee (diff)
downloadzig-834218d789430ac238e5ef4fa99cfe4bcf006f2d.tar.gz
zig-834218d789430ac238e5ef4fa99cfe4bcf006f2d.zip
Fix remaining variadic formatted prints
Used a series of regex searches to try to find as many instances of the old pattern as I could and update them.
Diffstat (limited to 'lib/std/crypto')
-rw-r--r--lib/std/crypto/benchmark.zig12
1 files changed, 6 insertions, 6 deletions
diff --git a/lib/std/crypto/benchmark.zig b/lib/std/crypto/benchmark.zig
index 95761b7ba6..b8bb69419d 100644
--- a/lib/std/crypto/benchmark.zig
+++ b/lib/std/crypto/benchmark.zig
@@ -125,9 +125,9 @@ fn mode(comptime x: comptime_int) comptime_int {
fn printPad(stdout: var, s: []const u8) !void {
var i: usize = 0;
while (i < 12 - s.len) : (i += 1) {
- try stdout.print(" ");
+ try stdout.print(" ", .{});
}
- try stdout.print("{}", s);
+ try stdout.print("{}", .{s});
}
pub fn main() !void {
@@ -142,7 +142,7 @@ pub fn main() !void {
var i: usize = 1;
while (i < args.len) : (i += 1) {
if (std.mem.eql(u8, args[i], "--mode")) {
- try stdout.print("{}\n", builtin.mode);
+ try stdout.print("{}\n", .{builtin.mode});
return;
} else if (std.mem.eql(u8, args[i], "--seed")) {
i += 1;
@@ -174,7 +174,7 @@ pub fn main() !void {
if (filter == null or std.mem.indexOf(u8, H.name, filter.?) != null) {
const throughput = try benchmarkHash(H.ty, mode(32 * MiB));
try printPad(stdout, H.name);
- try stdout.print(": {} MiB/s\n", throughput / (1 * MiB));
+ try stdout.print(": {} MiB/s\n", .{throughput / (1 * MiB)});
}
}
@@ -182,7 +182,7 @@ pub fn main() !void {
if (filter == null or std.mem.indexOf(u8, M.name, filter.?) != null) {
const throughput = try benchmarkMac(M.ty, mode(128 * MiB));
try printPad(stdout, M.name);
- try stdout.print(": {} MiB/s\n", throughput / (1 * MiB));
+ try stdout.print(": {} MiB/s\n", .{throughput / (1 * MiB)});
}
}
@@ -190,7 +190,7 @@ pub fn main() !void {
if (filter == null or std.mem.indexOf(u8, E.name, filter.?) != null) {
const throughput = try benchmarkKeyExchange(E.ty, mode(1000));
try printPad(stdout, E.name);
- try stdout.print(": {} exchanges/s\n", throughput);
+ try stdout.print(": {} exchanges/s\n", .{throughput});
}
}
}