authorgravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2018-04-24 21:23:03-04:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2018-04-24 21:23:03-04:00
log84391af7b8951735ec4719a6495ac37c032a1e36
tree319c5d56b99c36585e1e018d47f5979111b35fe6
parent1d998d5dce73d8d500dee5e41a3dca92a7f9b03e

convert NOTE to TODO so we catch it later

See #363 For Complex as a builtin type, see discussion in #949

2 files changed, 1 insertions(+), 3 deletions(-)

std/math/complex/index.zig-1
...@@ -23,7 +23,6 @@ pub const sqrt = @import("sqrt.zig").sqrt;...@@ -23,7 +23,6 @@ pub const sqrt = @import("sqrt.zig").sqrt;
23pub const tanh = @import("tanh.zig").tanh;23pub const tanh = @import("tanh.zig").tanh;
24pub const tan = @import("tan.zig").tan;24pub const tan = @import("tan.zig").tan;
2525
26// NOTE: Make this a builtin at some point?
27pub fn Complex(comptime T: type) type {26pub fn Complex(comptime T: type) type {
28 return struct {27 return struct {
29 const Self = this;28 const Self = this;
std/math/complex/sqrt.zig+1-2
...@@ -4,8 +4,7 @@ const math = std.math;...@@ -4,8 +4,7 @@ const math = std.math;
4const cmath = math.complex;4const cmath = math.complex;
5const Complex = cmath.Complex;5const Complex = cmath.Complex;
66
7// NOTE: Returning @typeOf(z) here causes issues when trying to access the value. This is7// TODO when #733 is solved this can be @typeOf(z) instead of Complex(@typeOf(z.re))
8// why we currently assign re, im parts to a new value explicitly for all tests.
9pub fn sqrt(z: var) Complex(@typeOf(z.re)) {8pub fn sqrt(z: var) Complex(@typeOf(z.re)) {
10 const T = @typeOf(z.re);9 const T = @typeOf(z.re);
1110