Skip to content

Commit

Permalink
Avoid qt containing detachment, remove some auto use
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Nov 26, 2019
1 parent bc6c3e5 commit f086d4e
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/analysis/raster/qgsrastercalculator.cpp
Expand Up @@ -163,13 +163,14 @@ QgsRasterCalculator::Result QgsRasterCalculator::processCalculation( QgsFeedback
// Map of raster names -> blocks
std::map<QString, std::unique_ptr<QgsRasterBlock>> inputBlocks;
std::map<QString, QgsRasterCalculatorEntry> uniqueRasterEntries;
for ( const auto &r : calcNode->findNodes( QgsRasterCalcNode::Type::tRasterRef ) )
const QList<const QgsRasterCalcNode *> rasterRefNodes = calcNode->findNodes( QgsRasterCalcNode::Type::tRasterRef );
for ( const QgsRasterCalcNode *r : rasterRefNodes )
{
QString layerRef( r->toString().remove( 0, 1 ) );
layerRef.chop( 1 );
if ( ! inputBlocks.count( layerRef ) )
{
for ( const auto &ref : mRasterEntries )
for ( const QgsRasterCalculatorEntry &ref : qgis::as_const( mRasterEntries ) )
{
if ( ref.ref == layerRef )
{
Expand Down

0 comments on commit f086d4e

Please sign in to comment.