mirror of https://github.com/goccy/go-json.git
Removed dependency on xerrors
This commit is contained in:
parent
aae63769a1
commit
e562358cdf
|
@ -8,8 +8,6 @@ import (
|
||||||
"strings"
|
"strings"
|
||||||
"sync"
|
"sync"
|
||||||
"unsafe"
|
"unsafe"
|
||||||
|
|
||||||
"golang.org/x/xerrors"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// A Token holds a value of one of these types:
|
// A Token holds a value of one of these types:
|
||||||
|
@ -222,7 +220,7 @@ func (d *Decoder) compile(typ *rtype) (decoder, error) {
|
||||||
case reflect.Float64:
|
case reflect.Float64:
|
||||||
return d.compileFloat64()
|
return d.compileFloat64()
|
||||||
}
|
}
|
||||||
return nil, xerrors.Errorf("unknown type %s", typ)
|
return nil, &UnsupportedTypeError{Type: rtype2type(typ)}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (d *Decoder) compilePtr(typ *rtype) (decoder, error) {
|
func (d *Decoder) compilePtr(typ *rtype) (decoder, error) {
|
||||||
|
|
2
go.mod
2
go.mod
|
@ -1,5 +1,3 @@
|
||||||
module github.com/goccy/go-json
|
module github.com/goccy/go-json
|
||||||
|
|
||||||
go 1.12
|
go 1.12
|
||||||
|
|
||||||
require golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543
|
|
||||||
|
|
Loading…
Reference in New Issue