From 84391af7b8951735ec4719a6495ac37c032a1e36 Mon Sep 17 00:00:00 2001 From: Andrew Kelley Date: Tue, 24 Apr 2018 21:23:03 -0400 Subject: [PATCH] convert NOTE to TODO so we catch it later See #363 For Complex as a builtin type, see discussion in #949 --- std/math/complex/index.zig | 1 - std/math/complex/sqrt.zig | 3 +-- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/std/math/complex/index.zig b/std/math/complex/index.zig index 24f726453f..a4d493307e 100644 --- a/std/math/complex/index.zig +++ b/std/math/complex/index.zig @@ -23,7 +23,6 @@ pub const sqrt = @import("sqrt.zig").sqrt; pub const tanh = @import("tanh.zig").tanh; pub const tan = @import("tan.zig").tan; -// NOTE: Make this a builtin at some point? pub fn Complex(comptime T: type) type { return struct { const Self = this; diff --git a/std/math/complex/sqrt.zig b/std/math/complex/sqrt.zig index 02e6390572..afda69f7c9 100644 --- a/std/math/complex/sqrt.zig +++ b/std/math/complex/sqrt.zig @@ -4,8 +4,7 @@ const math = std.math; const cmath = math.complex; const Complex = cmath.Complex; -// NOTE: Returning @typeOf(z) here causes issues when trying to access the value. This is -// why we currently assign re, im parts to a new value explicitly for all tests. +// TODO when #733 is solved this can be @typeOf(z) instead of Complex(@typeOf(z.re)) pub fn sqrt(z: var) Complex(@typeOf(z.re)) { const T = @typeOf(z.re);