Skip to content
Snippets Groups Projects
Commit 935101ee authored by Marco Clemencic's avatar Marco Clemencic
Browse files

Fix gcc12 warnings

See merge request !1403
parents 8297be8f de9ab00c
No related branches found
No related tags found
1 merge request!1403Fix gcc12 warnings
Pipeline #4964224 passed
......@@ -117,7 +117,15 @@ static std::unique_ptr<gp::PropertyValue> GetPropertyValue( const gp::Node* node
auto vvalue = GetPropertyValue( &child.children[1], catalog, units );
result.emplace( kvalue->ToString(), vvalue->ToString() );
}
#if __GNUC__ >= 12
# pragma GCC diagnostic push
// hide gcc 12 warning (false positive? see https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107138)
# pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
#endif
value = std::make_unique<gp::PropertyValue>( std::move( result ) );
#if __GNUC__ >= 12
# pragma GCC diagnostic pop
#endif
break;
}
// ------------------------------------------------------------------------
......
......@@ -33,10 +33,9 @@ namespace GaudiTesting {
using GaudiAlgorithm::GaudiAlgorithm;
~DestructorCheckAlg() override {
// do not print messages if we are created in genconf
const std::string cmd = System::cmdLineArgs()[0];
if ( cmd.find( "genconf" ) != std::string::npos ) return;
std::cout << "Destructor of " << name() << std::endl;
if ( System::cmdLineArgs()[0].find( "genconf" ) == std::string::npos ) {
std::cout << "Destructor of " << name() << std::endl;
}
}
StatusCode execute() override {
info() << "Executing " << name() << endmsg;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment