graph/formats/dot,travis: update gocc version
MODIFY
.travis.yml
.travis.yml
@@ -43,7 +43,7 @@ before_install:
- go get golang.org/x/tools/cmd/cover
- go get github.com/mattn/goveralls
# Required for dot parser checks.
- - ./.travis/install-gocc.sh 0e2cfc030005b281b2e5a2de04fa7fe1d5063722
+ - ./.travis/install-gocc.sh 66c61e91b3657c517a6f89d2837d370e61fb9430
addons:
apt:

MODIFY
graph/formats/dot/internal/errors/errors.go
graph/formats/dot/internal/errors/errors.go
package errors
import (
- "bytes"
"fmt"
+ "strings"
"gonum.org/v1/gonum/graph/formats/dot/internal/token"
)
@@ -31,7 +31,7 @@ type Error struct {
}
func (e *Error) String() string {
- w := new(bytes.Buffer)
+ w := new(strings.Builder)
fmt.Fprintf(w, "Error")
if e.Err != nil {
fmt.Fprintf(w, " %s\n", e.Err)
@@ -52,7 +52,7 @@ func (e *Error) String() string {
}
func (e *Error) Error() string {
- w := new(bytes.Buffer)
+ w := new(strings.Builder)
fmt.Fprintf(w, "Error in S%d: %s, %s", e.StackTop, token.TokMap.TokenString(e.ErrorToken), e.ErrorToken.Pos.String())
if e.Err != nil {
fmt.Fprintf(w, ": %+v", e.Err)

MODIFY
graph/formats/dot/internal/parser/parser.go
graph/formats/dot/internal/parser/parser.go
package parser
import (
- "bytes"
"fmt"
+ "strings"
parseError "gonum.org/v1/gonum/graph/formats/dot/internal/errors"
"gonum.org/v1/gonum/graph/formats/dot/internal/token"
@@ -76,7 +76,7 @@ func (s *stack) popN(items int) []Attrib {
}
func (s *stack) String() string {
- w := new(bytes.Buffer)
+ w := new(strings.Builder)
fmt.Fprintf(w, "stack:\n")
for i, st := range s.state {
fmt.Fprintf(w, "\t%d: %d , ", i, st)

graph/formats/dot,travis: update gocc version