[GODRIVER-1306] Add Equal methods for bson/bsoncore Created: 09/Sep/19 Updated: 28/Mar/23 Resolved: 28/Mar/23 |
|
| Status: | Closed |
| Project: | Go Driver |
| Component/s: | BSON |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Divjot Arora (Inactive) | Assignee: | Unassigned |
| Resolution: | Won't Do | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Documentation Changes Summary: | 1. What would you like to communicate to the user about this feature? |
| Description |
|
The bsoncore.Value type has an Equal method that compares the value bytes. While technically correct, we should add more general-purpose equality methods that check for semantic equality (i.e. int32(1) == int64(1)). This could be done at the document and/or value levels. |