From 404c87b06afbeebfea6c839665918c7bd1328d74 Mon Sep 17 00:00:00 2001 From: Andrew Kelley Date: Mon, 14 Jan 2019 18:11:17 -0500 Subject: [PATCH] fix incorrect parameter names for std.math.atan2 --- std/math/atan2.zig | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/std/math/atan2.zig b/std/math/atan2.zig index b3e45ba045..a7757132d7 100644 --- a/std/math/atan2.zig +++ b/std/math/atan2.zig @@ -22,10 +22,10 @@ const std = @import("../index.zig"); const math = std.math; const assert = std.debug.assert; -pub fn atan2(comptime T: type, x: T, y: T) T { +pub fn atan2(comptime T: type, y: T, x: T) T { return switch (T) { - f32 => atan2_32(x, y), - f64 => atan2_64(x, y), + f32 => atan2_32(y, x), + f64 => atan2_64(y, x), else => @compileError("atan2 not implemented for " ++ @typeName(T)), }; }