core: convert weightsystem_t and weightsystem_table to C++

As for cylinders, this had to be done simultaneously,

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2024-05-29 07:03:03 +02:00 committed by bstoeger
parent 28520da655
commit 640ecb345b
28 changed files with 137 additions and 247 deletions

View file

@ -745,9 +745,9 @@ static void parse_tag(struct dive *dive, std::string_view tag, std::string_view
} else if (tag == "altitude") {
uemis_get_index(val, dive->dcs[0].surface_pressure.mbar);
} else if (tag == "f32Weight") {
weightsystem_t ws = empty_weightsystem;
weightsystem_t ws;
uemis_get_weight(val, ws, dive->dcs[0].diveid);
add_cloned_weightsystem(&dive->weightsystems, ws);
dive->weightsystems.push_back(std::move(ws));
} else if (tag == "notes") {
uemis_add_string(val, &dive->notes, " ");
} else if (tag == "u8DiveSuit") {