Skip to content

Commit

Permalink
GODRIVER-2046 [master] Return clearer error when truncating a float64…
Browse files Browse the repository at this point in the history
… to float32 without the truncate tag (#1449)

Co-authored-by: Ernie Hershey <ernie.hershey@mongodb.com>
  • Loading branch information
blink1073 and ehershey committed Nov 2, 2023
1 parent b593d81 commit 6ed544f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion bson/bsoncodec/default_value_decoders.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import (

var (
defaultValueDecoders DefaultValueDecoders
errCannotTruncate = errors.New("float64 can only be truncated to an integer type when truncation is enabled")
errCannotTruncate = errors.New("float64 can only be truncated to a lower precision type when truncation is enabled")
)

type decodeBinaryError struct {
Expand Down

0 comments on commit 6ed544f

Please sign in to comment.