[Boost-bugs] [Boost C++ Libraries] #3617: big warnings from simple use of Boost.Concept_check

Subject: [Boost-bugs] [Boost C++ Libraries] #3617: big warnings from simple use of Boost.Concept_check
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2009-11-12 23:55:30


#3617: big warnings from simple use of Boost.Concept_check
-------------------------------------+--------------------------------------
 Reporter: eric_niebler | Owner: jsiek
     Type: Bugs | Status: new
Milestone: Boost 1.42.0 | Component: concept_check
  Version: Boost Development Trunk | Severity: Cosmetic
 Keywords: warning concept check |
-------------------------------------+--------------------------------------
 The following code causes at least msvc and gcc to complain loudly:

 {{{
 #include <boost/concept_check.hpp>
 #include <boost/concept/requires.hpp>

 template<typename T>
 BOOST_CONCEPT_REQUIRES(
     ((boost::UnaryFunction<T, void, int &>)), (void))
 foo(T const &)
 {
 }

 void bar(int &) {}

 int main()
 {
     foo(&bar);
 }
 }}}

 The problem is that the definition of UnaryFunction (and most of the
 concepts) causes a non-static reference data member in a class without a
 constructor.

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/3617>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:01 UTC