Opened 9 years ago

Closed 9 years ago

#8727 closed Bugs (fixed)

extra ";" warning with -pedantic options under g++ 4.7.2 compiler

Reported by: Anthony JOURDAN <anthony.jourdan@…> Owned by: Frank Mori Hess
Milestone: Boost 1.54.0 Component: signals2
Version: Boost 1.54.0 Severity: Optimization
Keywords: -pedantic warning signals2 Cc:

Description

My current boost version is boost_1_54_0_beta1.

In the signals2 component, there is two 'extra ";"' warnings with the -pedantic option under g++ 4.7.2 compiler.

In the boost\signals2\signal.hpp line 58:

// free swap function, findable by ADL
template<typename Signature,
  typename Combiner,
  typename Group,
  typename GroupCompare,
  typename SlotFunction,
  typename ExtendedSlotFunction,
  typename Mutex>
  void swap(
   signal<Signature, Combiner, Group, GroupCompare, SlotFunction, ExtendedSlotFunction, Mutex> &sig1,
   signal<Signature, Combiner, Group, GroupCompare, SlotFunction, ExtendedSlotFunction, Mutex> &sig2)
{
  sig1.swap(sig2);
};

In the boost\signals2\detail\signal_template.hpp line 740.

#ifdef BOOST_NO_CXX11_VARIADIC_TEMPLATES
    // free swap function for signalN classes, findable by ADL
    template<BOOST_SIGNALS2_SIGNAL_TEMPLATE_DECL(BOOST_SIGNALS2_NUM_ARGS)>
      void swap(
        BOOST_SIGNALS2_SIGNAL_CLASS_NAME(BOOST_SIGNALS2_NUM_ARGS) <BOOST_SIGNALS2_SIGNAL_TEMPLATE_INSTANTIATION> &sig1,
        BOOST_SIGNALS2_SIGNAL_CLASS_NAME(BOOST_SIGNALS2_NUM_ARGS) <BOOST_SIGNALS2_SIGNAL_TEMPLATE_INSTANTIATION> &sig2 )
    {
      sig1.swap(sig2);
    };
#endif

Change History (2)

comment:1 by Frank Mori Hess, 9 years ago

(In [85042]) Removed some spurious semicolons. Refs #8727

comment:2 by Frank Mori Hess, 9 years ago

Resolution: fixed
Status: newclosed

Fix has been merged to release branch.

Note: See TracTickets for help on using tickets.