[CXX-2145] Coverity analysis defect 115920: Missing move assignment operator Created: 14/Dec/20 Updated: 27/Oct/23 Resolved: 24/Jul/23 |
|
| Status: | Closed |
| Project: | C++ Driver |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Coverity Collector User | Assignee: | Unassigned |
| Resolution: | Works as Designed | Votes: | 0 |
| Labels: | size-small | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Epic Link: | CXX-2632 |
| Quarter: | FY24Q2 |
| Description |
|
Missing move assignment operator This class does not have a user-written move assignment operator and its copy assignment operator is found to be applied to rvalue(s), which can be moved to possibly enhance program performance had the move assignment operator been in place. Class lacks a user-written move assignment operator |
| Comments |
| Comment by Kevin Albertson [ 24/Jul/23 ] |
|
I expect the default copy constructor is called since no move constructor is called:
bsoncxx::types::bson_value::view does not own data. I expect calling the copy-constructor on move is OK. Closing as "Works as Designed". |
| Comment by Coverity Collector User [ 14/Dec/20 ] |
|
A new defect has been detected and assigned to kevin.albertson in Coverity Connect. |