]> Cypherpunks repositories - gostls13.git/commitdiff
fmt: enable the complex tests now that 8g supports complex
authorRob Pike <r@golang.org>
Tue, 9 Mar 2010 22:17:14 +0000 (14:17 -0800)
committerRob Pike <r@golang.org>
Tue, 9 Mar 2010 22:17:14 +0000 (14:17 -0800)
R=rsc
CC=golang-dev
https://golang.org/cl/357043

src/pkg/fmt/fmt_test.go

index 3f8674639af8f9d44ef7f815268bb6860d2fb1ae..b601b6ef57419334ad45b518f74824d490655617 100644 (file)
@@ -119,7 +119,6 @@ var fmttests = []fmtTest{
        fmtTest{"% .3g", -1.0, "-1"},
        fmtTest{"% .3g", 1.0, " 1"},
 
-       /* TODO: Enable when complex support is in all compilers
        // complex values
        fmtTest{"%+.3e", 0i, "(+0.000e+00+0.000e+00i)"},
        fmtTest{"%+.3f", 0i, "(+0.000+0.000i)"},
@@ -139,7 +138,6 @@ var fmttests = []fmtTest{
        fmtTest{"% .3E", -1 - 2i, "(-1.000E+00-2.000E+00i)"},
        fmtTest{"%+.3g", complex64(1 + 2i), "(+1+2i)"},
        fmtTest{"%+.3g", complex128(1 + 2i), "(+1+2i)"},
-       */
 
        // erroneous formats
        fmtTest{"", 2, "?(extra int=2)"},
@@ -232,12 +230,10 @@ var fmttests = []fmtTest{
        fmtTest{"%v", &array, "&[1 2 3 4 5]"},
        fmtTest{"%v", &iarray, "&[1 hello 2.5 <nil>]"},
 
-       /* TODO: Enable when complex support is in all compilers
        // complexes with %v
        fmtTest{"%v", 1 + 2i, "(1+2i)"},
        fmtTest{"%v", complex64(1 + 2i), "(1+2i)"},
        fmtTest{"%v", complex128(1 + 2i), "(1+2i)"},
-       */
 
        // structs
        fmtTest{"%v", A{1, 2, "a", []int{1, 2}}, `{1 2 a [1 2]}`},