diff options
author | Ian Lance Taylor <ian@gcc.gnu.org> | 2011-12-14 15:41:54 +0000 |
---|---|---|
committer | Ian Lance Taylor <ian@gcc.gnu.org> | 2011-12-14 15:41:54 +0000 |
commit | d5363590597572228d4e0d0ae13f3469176ceb14 (patch) | |
tree | e3de46cbc89d82ca1f49843fe2e1e670db67795e /gcc | |
parent | ef0d4c4d9937276c8ff818ecb0b92925d322d3bd (diff) | |
download | gcc-d5363590597572228d4e0d0ae13f3469176ceb14.zip gcc-d5363590597572228d4e0d0ae13f3469176ceb14.tar.gz gcc-d5363590597572228d4e0d0ae13f3469176ceb14.tar.bz2 |
libgo: Update to weekly.2011-12-06.
From-SVN: r182338
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/testsuite/go.test/test/fixedbugs/bug120.go | 8 | ||||
-rw-r--r-- | gcc/testsuite/go.test/test/fixedbugs/bug260.go | 12 |
2 files changed, 10 insertions, 10 deletions
diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug120.go b/gcc/testsuite/go.test/test/fixedbugs/bug120.go index 2a71957..bf401bf 100644 --- a/gcc/testsuite/go.test/test/fixedbugs/bug120.go +++ b/gcc/testsuite/go.test/test/fixedbugs/bug120.go @@ -41,16 +41,16 @@ func main() { ok := true for i := 0; i < len(tests); i++ { t := tests[i] - v := strconv.Ftoa64(t.f, 'g', -1) + v := strconv.FormatFloat(t.f, 'g', -1, 64) if v != t.out { println("Bad float64 const:", t.in, "want", t.out, "got", v) - x, err := strconv.Atof64(t.out) + x, err := strconv.ParseFloat(t.out, 64) if err != nil { println("bug120: strconv.Atof64", t.out) panic("fail") } - println("\twant exact:", strconv.Ftoa64(x, 'g', 1000)) - println("\tgot exact: ", strconv.Ftoa64(t.f, 'g', 1000)) + println("\twant exact:", strconv.FormatFloat(x, 'g', 1000, 64)) + println("\tgot exact: ", strconv.FormatFloat(t.f, 'g', 1000, 64)) ok = false } } diff --git a/gcc/testsuite/go.test/test/fixedbugs/bug260.go b/gcc/testsuite/go.test/test/fixedbugs/bug260.go index 34757c7..91dc89f 100644 --- a/gcc/testsuite/go.test/test/fixedbugs/bug260.go +++ b/gcc/testsuite/go.test/test/fixedbugs/bug260.go @@ -24,8 +24,8 @@ func main() { report := len(os.Args) > 1 status := 0 var b1 [10]T1 - a0, _ := strconv.Btoui64(fmt.Sprintf("%p", &b1[0])[2:], 16) - a1, _ := strconv.Btoui64(fmt.Sprintf("%p", &b1[1])[2:], 16) + a0, _ := strconv.ParseUint(fmt.Sprintf("%p", &b1[0])[2:], 16, 64) + a1, _ := strconv.ParseUint(fmt.Sprintf("%p", &b1[1])[2:], 16, 64) if a1 != a0+1 { fmt.Println("FAIL") if report { @@ -34,8 +34,8 @@ func main() { status = 1 } var b2 [10]T2 - a0, _ = strconv.Btoui64(fmt.Sprintf("%p", &b2[0])[2:], 16) - a1, _ = strconv.Btoui64(fmt.Sprintf("%p", &b2[1])[2:], 16) + a0, _ = strconv.ParseUint(fmt.Sprintf("%p", &b2[0])[2:], 16, 64) + a1, _ = strconv.ParseUint(fmt.Sprintf("%p", &b2[1])[2:], 16, 64) if a1 != a0+2 { if status == 0 { fmt.Println("FAIL") @@ -46,8 +46,8 @@ func main() { } } var b4 [10]T4 - a0, _ = strconv.Btoui64(fmt.Sprintf("%p", &b4[0])[2:], 16) - a1, _ = strconv.Btoui64(fmt.Sprintf("%p", &b4[1])[2:], 16) + a0, _ = strconv.ParseUint(fmt.Sprintf("%p", &b4[0])[2:], 16, 64) + a1, _ = strconv.ParseUint(fmt.Sprintf("%p", &b4[1])[2:], 16, 64) if a1 != a0+4 { if status == 0 { fmt.Println("FAIL") |