[Boost-bugs] [Boost C++ Libraries] #2494: compile errors in function_template.hpp when BOOST_NO_EXCEPTIONS defined

Subject: [Boost-bugs] [Boost C++ Libraries] #2494: compile errors in function_template.hpp when BOOST_NO_EXCEPTIONS defined
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2008-11-12 09:42:44


#2494: compile errors in function_template.hpp when BOOST_NO_EXCEPTIONS defined
---------------------------------------------------+------------------------
 Reporter: ANDREW CHITTENDEN <andyc_at_[hidden]> | Type: Bugs
   Status: new | Milestone: Boost 1.38.0
Component: None | Version: Boost 1.36.0
 Severity: Problem | Keywords:
---------------------------------------------------+------------------------
 This is on Boost 1.37.0 - there's no version for that at the moment in the
 Version pull down for submitting new bugs.

 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/detail/maybe_include.hpp:23,
                  from
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function2.hpp:11,
                  from
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/signals/detail/named_slot_map.hpp:18,
                  from libs/signals/src/named_slot_map.cpp:12:
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:965:
 error: declaration of 'class R'
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:652:
 error: shadows template parm 'class R'
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:965:
 error: declaration of 'class T0'
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:653:
 error: shadows template parm 'class T0'
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:965:
 error: declaration of 'class T1'
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:653:
 error: shadows template parm 'class T1'
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:979:
 error: declaration of 'class R'
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:652:
 error: shadows template parm 'class R'
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:979:
 error: declaration of 'class T0'
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:653:
 error: shadows template parm 'class T0'
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:979:
 error: declaration of 'class T1'
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:653:
 error: shadows template parm 'class T1'
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:983:
 error: invalid use of incomplete type 'class boost::function2<R, T0, T1>'
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:667:
 error: declaration of 'class boost::function2<R, T0, T1>'
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:994:
 error: declaration of 'class R'
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:652:
 error: shadows template parm 'class R'
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:994:
 error: declaration of 'class T0'
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:653:
 error: shadows template parm 'class T0'
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:994:
 error: declaration of 'class T1'
 /home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:653:
 error: shadows template parm 'class T1'

 This patch fixes it:

 ===== boost/function/function_template.hpp 1.1 vs edited =====
 --- 1.1/boost/function/function_template.hpp 2008-11-06 09:48:36 +00:00
 +++ edited/boost/function/function_template.hpp 2008-11-12 09:37:06 +00:00
 @@ -950,10 +950,10 @@
            f.vtable->manager(f.functor, this->functor,
                              boost::detail::function::move_functor_tag);
                   f.vtable = 0;
 -#if !defined(BOOST_NO_EXCEPTIONS)
          } else {
            clear();
          }
 +#if !defined(BOOST_NO_EXCEPTIONS)
        } catch (...) {
          vtable = 0;
          throw;

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/2494>
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:49:59 UTC