diff options
Diffstat (limited to 'lib/binstruct/structs.go')
-rw-r--r-- | lib/binstruct/structs.go | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/binstruct/structs.go b/lib/binstruct/structs.go index 2f224dd..72fd5e5 100644 --- a/lib/binstruct/structs.go +++ b/lib/binstruct/structs.go @@ -183,7 +183,10 @@ func getStructHandler(typ reflect.Type) structHandler { h, err := genStructHandler(typ) if err != nil { - panic(err) + panic(&InvalidTypeError{ + Type: typ, + Err: err, + }) } structCache[typ] = h return h |