Remove unnecessary vars

This commit is contained in:
Masaaki Goshima 2021-06-03 18:59:52 +09:00
parent de4e97ed09
commit 45780881a4
2 changed files with 2 additions and 11 deletions

View File

@ -7,6 +7,7 @@ import (
"unsafe"
"github.com/goccy/go-json/internal/decoder"
"github.com/goccy/go-json/internal/errors"
"github.com/goccy/go-json/internal/runtime"
)
@ -72,7 +73,7 @@ func validateEndBuf(src []byte, cursor int64) error {
case nul:
return nil
}
return errSyntax(
return errors.ErrSyntax(
fmt.Sprintf("invalid character '%c' after top-level value", src[cursor]),
cursor+1,
)

View File

@ -37,13 +37,3 @@ type UnmarshalTypeError = errors.UnmarshalTypeError
type UnsupportedTypeError = errors.UnsupportedTypeError
type UnsupportedValueError = errors.UnsupportedValueError
var (
errExceededMaxDepth = errors.ErrExceededMaxDepth
errNotAtBeginningOfValue = errors.ErrNotAtBeginningOfValue
errUnexpectedEndOfJSON = errors.ErrUnexpectedEndOfJSON
errExpected = errors.ErrExpected
errInvalidCharacter = errors.ErrInvalidCharacter
errSyntax = errors.ErrSyntax
errMarshaler = errors.ErrMarshaler
)