core: make split_dive() and related functions return unique_ptrs

This prepares for turning the dive table into a list of owning
pointers.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2024-06-03 21:50:08 +02:00 committed by bstoeger
parent c9d4ce0c15
commit 0ef497c3c9
4 changed files with 71 additions and 110 deletions

View file

@ -196,7 +196,7 @@ struct MergeTrips : public TripBase {
class SplitDivesBase : public DiveListBase {
protected:
SplitDivesBase(dive *old, std::array<dive *, 2> newDives);
SplitDivesBase(dive *old, std::array<std::unique_ptr<dive>, 2> newDives);
private:
void undoit() override;
void redoit() override;