mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#6491 Fix range iterators which was creating data copies (clang10 warnings).
This commit is contained in:
@@ -1193,14 +1193,14 @@ void RimWellPlotTools::calculateValueOptionsForTimeSteps(
|
||||
QString dateFormatString;
|
||||
{
|
||||
std::vector<QDateTime> allTimeSteps;
|
||||
for ( const std::pair<QDateTime, std::set<RifDataSourceForRftPlt>>& timeStepPair : timestepsToShowWithSources )
|
||||
for ( const std::pair<const QDateTime, std::set<RifDataSourceForRftPlt>>& timeStepPair : timestepsToShowWithSources )
|
||||
{
|
||||
allTimeSteps.push_back( timeStepPair.first );
|
||||
}
|
||||
dateFormatString = RiaQDateTimeTools::createTimeFormatStringFromDates( allTimeSteps );
|
||||
}
|
||||
|
||||
for ( const std::pair<QDateTime, std::set<RifDataSourceForRftPlt>>& timeStepPair : timestepsToShowWithSources )
|
||||
for ( const std::pair<const QDateTime, std::set<RifDataSourceForRftPlt>>& timeStepPair : timestepsToShowWithSources )
|
||||
{
|
||||
QString optionText = RiaQDateTimeTools::toStringUsingApplicationLocale( timeStepPair.first, dateFormatString );
|
||||
|
||||
|
||||
@@ -1230,7 +1230,7 @@ QList<caf::PdmOptionItemInfo> RimGeoMechCase::calculateValueOptions( const caf::
|
||||
std::map<std::string, QString> addressesInFile =
|
||||
geoMechData()->femPartResults()->addressesInElementPropertyFiles( paths );
|
||||
|
||||
for ( const std::string elementProperty : elementProperties )
|
||||
for ( const std::string& elementProperty : elementProperties )
|
||||
{
|
||||
QString result = QString::fromStdString( elementProperty );
|
||||
QString filename = findFileNameForElementProperty( elementProperty, addressesInFile );
|
||||
|
||||
@@ -612,7 +612,7 @@ QList<caf::PdmOptionItemInfo>
|
||||
std::map<std::string, QString> addressesInFile =
|
||||
geoMechCase->geoMechData()->femPartResults()->addressesInElementPropertyFiles( paths );
|
||||
|
||||
for ( const std::string elementProperty : elementProperties )
|
||||
for ( const std::string& elementProperty : elementProperties )
|
||||
{
|
||||
QString result = QString::fromStdString( elementProperty );
|
||||
QString filename = geoMechCase->findFileNameForElementProperty( elementProperty, addressesInFile );
|
||||
|
||||
@@ -1086,7 +1086,7 @@ void RimEnsembleCurveSet::showCurves( bool show )
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimEnsembleCurveSet::markCachedDataForPurge()
|
||||
{
|
||||
for ( const auto curve : m_curves )
|
||||
for ( const auto& curve : m_curves )
|
||||
{
|
||||
curve->markCachedDataForPurge();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user