Skip to content

Commit

Permalink
add commit
Browse files Browse the repository at this point in the history
  • Loading branch information
tiltwind committed May 4, 2023
1 parent 64ed78d commit 25f3ccf
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions decode.go
Original file line number Diff line number Diff line change
Expand Up @@ -325,6 +325,11 @@ func (d *Decoder) DecodeValue() (interface{}, error) {
}

// decToDest decode data to dest value.
// Before and includes the version v1.12.1, it checks all possible types of the destination,
// and then decode the data according to the type.
// But there are too many cases, and it's impossible to handle all of them.
// After v1.12.1, it decodes the data first, and then set the value to the destination.
// If the destination is map, slice, array, it decodes separately.
func (d *Decoder) decToDest(dest reflect.Value) error {
destType := dest.Type()
destRawType := UnpackPtrType(destType)
Expand Down

0 comments on commit 25f3ccf

Please sign in to comment.