mark variables const

This commit is contained in:
Arne Morten Kvarving 2023-02-14 13:48:24 +01:00
parent a825a060c3
commit 24fda63778
2 changed files with 4 additions and 4 deletions

View File

@ -152,10 +152,10 @@ std::tuple<T,int,int> PackUnpack(T& in)
Opm::EclMpiSerializer ser(comm);
ser.pack(in);
size_t pos1 = ser.position();
const size_t pos1 = ser.position();
T out;
ser.unpack(out);
size_t pos2 = ser.position();
const size_t pos2 = ser.position();
return std::make_tuple(out, pos1, pos2);
}

View File

@ -46,10 +46,10 @@ std::tuple<T,int,int> PackUnpack(T& in)
Opm::Serialization::MemPacker packer;
Opm::Serializer ser(packer);
ser.pack(in);
size_t pos1 = ser.position();
const size_t pos1 = ser.position();
T out{};
ser.unpack(out);
size_t pos2 = ser.position();
const size_t pos2 = ser.position();
return std::make_tuple(std::move(out), pos1, pos2);
}