-
Type: Bug
-
Resolution: Unresolved
-
Priority: Unknown
-
None
-
Affects Version/s: None
-
Component/s: BSON
-
None
The MarshalValue function returns an error if you try to marshal a value like var v any = nil, despite the same value marshaling correctly to BSON "null" when using Marshal.
Check out an example using MarshalValue here. Check out an example using Marshal here.
Definition of done:
- Calling bson.MarshalValue(nil) returns type "bsontype.Null", an encoded BSON "null" value, and no error.
- related to
-
GODRIVER-2765 Add an "omitzero" BSON struct tag
- Backlog