Debian Codegraph @

transport/util.go

raw symbols SCIP
1 package transport
2
3 import (
4 "fmt"
5 "strings"
6 )
7
8 type badStringError struct {
9 what string
10 str string
11 }
12
13 func (e *badStringError) Error() string { return fmt.Sprintf("%s %q", e.what, e.str) }
14
15 func hasPort(s string) bool { return strings.LastIndex(s, ":") > strings.LastIndex(s, "]") }