From 41f59ab8736953baf5b4a4d23923b4cdc73fdeb5 Mon Sep 17 00:00:00 2001 From: Jon Evans Date: Sat, 22 Feb 2020 21:26:19 -0500 Subject: [PATCH] Avoid intermittent compiler crash in GCC 7.4 Somehow the previous way this statement was written can cause an internal compiler crash on gcc 7.4.0-1ubuntu1~18.04.1 sometimes. --- eeschema/tools/backannotate.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/eeschema/tools/backannotate.cpp b/eeschema/tools/backannotate.cpp index 9a7ff6c50c..258cefb210 100644 --- a/eeschema/tools/backannotate.cpp +++ b/eeschema/tools/backannotate.cpp @@ -175,8 +175,8 @@ int BACK_ANNOTATE::getPcbModulesFromString( const std::string& aPayload ) { // Add module to the map PCB_MODULE_DATA data( ref, footprint, value ); - m_pcbModules.insert( nearestItem, decltype( PCB_MODULES_MAP::value_type() )( path, - std::make_shared( data ) ) ); + m_pcbModules.insert( nearestItem, + std::make_pair( path, std::make_shared( data ) ) ); } } return errors;