summaryrefslogtreecommitdiff
path: root/src/pkg/math/big/rat.go
diff options
context:
space:
mode:
authorBrad Fitzpatrick <bradfitz@golang.org>2013-08-05 16:27:24 -0700
committerBrad Fitzpatrick <bradfitz@golang.org>2013-08-05 16:27:24 -0700
commitbfaa1d32f18bc59584e377b51432c7914d4ef459 (patch)
tree2bc2ffe299aeb0b13af8197578729c517b1c3acb /src/pkg/math/big/rat.go
parent4330c393a01e0fc86df9b0fe4ee142cc4c98a9c5 (diff)
downloadgo-bfaa1d32f18bc59584e377b51432c7914d4ef459.tar.gz
undo CL 12486043 / ab644299d124
Uglier. ??? original CL description all: use strings.IndexByte instead of Index where possible R=golang-dev, khr CC=golang-dev https://codereview.appspot.com/12486043 ??? R=golang-dev CC=golang-dev https://codereview.appspot.com/12485044
Diffstat (limited to 'src/pkg/math/big/rat.go')
-rw-r--r--src/pkg/math/big/rat.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/pkg/math/big/rat.go b/src/pkg/math/big/rat.go
index 31945aae8..39791ec6d 100644
--- a/src/pkg/math/big/rat.go
+++ b/src/pkg/math/big/rat.go
@@ -429,7 +429,7 @@ func (z *Rat) SetString(s string) (*Rat, bool) {
}
// check for a quotient
- sep := strings.IndexByte(s, '/')
+ sep := strings.Index(s, "/")
if sep >= 0 {
if _, ok := z.a.SetString(s[0:sep], 10); !ok {
return nil, false
@@ -443,7 +443,7 @@ func (z *Rat) SetString(s string) (*Rat, bool) {
}
// check for a decimal point
- sep = strings.IndexByte(s, '.')
+ sep = strings.Index(s, ".")
// check for an exponent
e := strings.IndexAny(s, "eE")
var exp Int