3 // Copyright 2010 The Go Authors. All rights reserved.
4 // Use of this source code is governed by a BSD-style
5 // license that can be found in the LICENSE file.
7 // Driver for complex division table defined in cmplxdivide1.go
8 // For details, see the comment at the top of in cmplxdivide.c.
25 var negzero = math.Copysign(0, -1)
27 func calike(a, b complex128) bool {
29 case cmplx.IsInf(a) && cmplx.IsInf(b):
31 case cmplx.IsNaN(a) && cmplx.IsNaN(b):
39 for _, t := range tests {
41 if !calike(x, t.out) {
46 fmt.Printf("%v/%v: expected %v error; got %v\n", t.f, t.g, t.out, x)
50 panic("cmplxdivide failed.")