From 9521991561bf574772ce48d38c299c488f3ef62d Mon Sep 17 00:00:00 2001 From: "Vicente J. Botet Escriba" Date: Sat, 20 Apr 2013 14:02:02 +0000 Subject: [PATCH 1/2] Concept: fix minor warning. [SVN r83983] --- include/boost/concept_check.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/boost/concept_check.hpp b/include/boost/concept_check.hpp index 9cfd281..292f37d 100644 --- a/include/boost/concept_check.hpp +++ b/include/boost/concept_check.hpp @@ -878,7 +878,7 @@ namespace boost typename BackInsertionSequence::const_reference r = cc.back(); ignore_unused_variable_warning(r); - }; + } S c; typename S::value_type t; }; From 168e60aa3d5238cd25b341661a6c53e638dd6c33 Mon Sep 17 00:00:00 2001 From: Jeremiah Willcock Date: Sat, 25 May 2013 02:11:20 +0000 Subject: [PATCH 2/2] Added unused attribute for new versions of GCC [SVN r84470] --- include/boost/concept/detail/general.hpp | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/include/boost/concept/detail/general.hpp b/include/boost/concept/detail/general.hpp index e3014c1..c88a1ed 100644 --- a/include/boost/concept/detail/general.hpp +++ b/include/boost/concept/detail/general.hpp @@ -65,10 +65,19 @@ struct requirement_ # endif +// Version check from https://svn.boost.org/trac/boost/changeset/82886 +// (boost/static_assert.hpp) +#if defined(__GNUC__) && ((__GNUC__ > 4) || ((__GNUC__ == 4) && (__GNUC_MINOR__ >= 7))) +#define BOOST_CONCEPT_UNUSED_TYPEDEF __attribute__((unused)) +#else +#define BOOST_CONCEPT_UNUSED_TYPEDEF /**/ +#endif + # define BOOST_CONCEPT_ASSERT_FN( ModelFnPtr ) \ typedef ::boost::concepts::detail::instantiate< \ &::boost::concepts::requirement_::failed> \ - BOOST_PP_CAT(boost_concept_check,__LINE__) + BOOST_PP_CAT(boost_concept_check,__LINE__) \ + BOOST_CONCEPT_UNUSED_TYPEDEF }}