]> Cypherpunks repositories - gostls13.git/commitdiff
math: avoid unused assignment in jn.go
authorTarmigan Casebolt <tarmigan@gmail.com>
Mon, 24 Aug 2015 02:51:33 +0000 (19:51 -0700)
committerBrad Fitzpatrick <bradfitz@golang.org>
Mon, 24 Aug 2015 14:34:36 +0000 (14:34 +0000)
Change-Id: Ie4f21bcd5849e994c63ec5bbda2dee6f3ec4da12
Reviewed-on: https://go-review.googlesource.com/13891
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>

src/math/jn.go

index a7909eb24cdd3f5e1fb23e4db7f996b230b8152d..ffb8a00f50f0187e6cc735e8f13c53ee24619db8 100644 (file)
@@ -200,13 +200,11 @@ func Jn(n int, x float64) float64 {
                                for i := n - 1; i > 0; i-- {
                                        di := float64(i + i)
                                        a, b = b, b*di/x-a
-                                       di -= 2
                                }
                        } else {
                                for i := n - 1; i > 0; i-- {
                                        di := float64(i + i)
                                        a, b = b, b*di/x-a
-                                       di -= 2
                                        // scale b to avoid spurious overflow
                                        if b > 1e100 {
                                                a /= b