Skip to content

fix spurious clang warning

Gerhard Raven requested to merge fix-spurious-clang-warning into master

Fix spurious clang-11 warning triggered by DataObjectHandle.h:

In file included from Gaudi/InstallArea/x86_64_v2-centos7-clang11-opt/include/GaudiKernel/DataObjectHandle.h:22:	
In file included from /cvmfs/lhcb.cern.ch/lib/lcg/releases/Boost/1.75.0-6a4e8/x86_64-centos7-clang11-opt/include/boost/algorithm/string.hpp:18:
In file included from /cvmfs/lhcb.cern.ch/lib/lcg/releases/Boost/1.75.0-6a4e8/x86_64-centos7-clang11-opt/include/boost/algorithm/string/std_containers_traits.hpp:23:
In file included from /cvmfs/lhcb.cern.ch/lib/lcg/releases/Boost/1.75.0-6a4e8/x86_64-centos7-clang11-opt/include/boost/algorithm/string/std/slist_traits.hpp:16:
/cvmfs/lhcb.cern.ch/lib/lcg/releases/gcc/10.3.0-f5826/x86_64-centos7/include/c++/10.3.0/ext/slist:460:7: warning: unknown attribute '__nodiscard__' ignored [-Wunknown-attributes]
      _GLIBCXX_NODISCARD bool
      ^
/cvmfs/lhcb.cern.ch/lib/lcg/releases/gcc/10.3.0-f5826/x86_64-centos7/include/c++/10.3.0/x86_64-pc-linux-gnu/bits/c++config.h:115:31: note: expanded from macro '_GLIBCXX_NODISCARD'
# define _GLIBCXX_NODISCARD [[__nodiscard__]]
                              ^

by including a more targeted header which includes less redundant code

Merge request reports

Loading