[CDRIVER-2829] Add a bson_copy_to_excluding_noinit variant taking a va_list Created: 18/Sep/18 Updated: 28/Oct/23 Resolved: 14/Dec/18 |
|
| Status: | Closed |
| Project: | C Driver |
| Component/s: | libbson |
| Affects Version/s: | None |
| Fix Version/s: | 1.14.0 |
| Type: | Improvement | Priority: | Minor - P4 |
| Reporter: | Kaitlin Mahar | Assignee: | Samantha Ritter (Inactive) |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | neweng | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Epic Link: | FY2019Q4 Quick Wins (C and CXX) | ||||||||
| Description |
|
SWIFT-195 introduced a variety of methods for transforming documents: taking a prefix, suffix, subsequence, etc. Ideally, we would implement these using bson_copy_to_excluding_nonit, to avoid having to round-trip the values we want do to keep through Swift when we put them into a new document. However, Swift by design does not allow calling variadic C functions, as discussed in the documentation here. It does, however, support calling functions that take a va_list. There is currently _bson_copy_to_excluding_va, but it's internal. Access to a variant of this method that lets us use a va_list to specify the fields to exclude would make these methods introduced in SWIFT-195 far more performant.
|
| Comments |
| Comment by Githook User [ 14/Dec/18 ] |
|
Author: {'username': 'samantharitter', 'email': 'samantha.ritter@10gen.com', 'name': 'samantharitter'}Message: |