memilio
memilio copied to clipboard
Using copy_person creates duplicate IDs
Bug description
Person::copy_person currently also copies the ID of the person. Currently, this is fine, as the function is used exclusively to copy an entire population in the World copy ctor.
However, using this function to duplicate a person in the same populitaion leads to non-unique IDs, which could cause issues elsewhere.
Version
Any
To reproduce
- Create an instance of Person.
- Call
copy_personand obtain a different instance sharing the same ID
Relevant log output
No response
Add any relevant information, e.g. used compiler, screenshots.
No response
Checklist
- [X] Attached labels, especially loc:: or model:: labels.
- [X] Linked to project
This will probably be fixed along with #757