mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
System: Enable and use c++20
Enable c++20 in top level cmake. Keep c++17 for GrpcInterface, as the protoc tool does not work with c++20. Several code adjustments to fix compiler issues.
This commit is contained in:
@@ -187,9 +187,19 @@ std::vector<std::string> RiaStdStringTools::splitString( const std::string& s, c
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
std::string RiaStdStringTools::joinStrings( const std::vector<std::string>& s, char delimiter )
|
||||
{
|
||||
std::string delimiterString( 1, delimiter );
|
||||
std::string joinedString;
|
||||
|
||||
return join( s.begin(), s.end(), delimiterString );
|
||||
for ( const auto& str : s )
|
||||
{
|
||||
if ( !joinedString.empty() )
|
||||
{
|
||||
joinedString += delimiter;
|
||||
}
|
||||
|
||||
joinedString += str;
|
||||
}
|
||||
|
||||
return joinedString;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user