changeset 57:08b2b9fce25c

Remove the complex constants; they're not very useful and pollute the namespace
author Chris Cannam
date Wed, 09 Jan 2013 21:35:37 +0000
parents 330f8b936092
children f6c70e462cc3
files complex.yeti test/test_complex.yeti
diffstat 2 files changed, 1 insertions(+), 13 deletions(-) [+]
line wrap: on
line diff
--- a/complex.yeti	Tue Jan 08 19:54:27 2013 +0000
+++ b/complex.yeti	Wed Jan 09 21:35:37 2013 +0000
@@ -68,9 +68,6 @@
    angle,
    add,
    scale,
-   i = complex 0 1,
-   one = complex 1 0,
-   zero = complex 0 0,
 } as {
    real is cplx -> number,
    imaginary is cplx -> number,
@@ -79,8 +76,5 @@
    angle is cplx -> number,
    add is cplx -> cplx -> cplx,
    scale is number -> cplx -> cplx,
-   i is cplx,
-   one is cplx,
-   zero is cplx,
 }
 
--- a/test/test_complex.yeti	Tue Jan 08 19:54:27 2013 +0000
+++ b/test/test_complex.yeti	Wed Jan 09 21:35:37 2013 +0000
@@ -1,6 +1,6 @@
 module test.test_complex;
 
-{ i, one, zero, real, imaginary, complex, magnitude, angle, add, scale }
+{ real, imaginary, complex, magnitude, angle, add, scale }
    = load complex;
 
 { compare } = load test.test;
@@ -40,12 +40,6 @@
     compare (scale 4 (complex 2 3)) (complex 8 12)
 ),
 
-"constants": \(
-    compare (complex 0 1) i and
-        compare (complex 1 0) one and
-        compare (complex 0 0) zero
-),
-
 ] is hash<string, () -> boolean>;