Opened 14 years ago

Closed 13 years ago

#2321 closed Bugs (fixed)

Cosmetic warning in function_types with g++ 4.3

Reported by: Joel Falcou <joel.falcou@…> Owned by: t_schwinger
Milestone: Boost 1.39.0 Component: function_types
Version: Boost 1.38.0 Severity: Problem
Keywords: Cc:

Description

Using function_types meta-functions raises this warning under g++ 4.3 (Linux Ubuntu 8.04) :

/usr/local/include/boost-1_36/boost/function_types/detail/pp_tags/preprocessed.hpp:55 warning: suggest parentheses around arithmetic in operand of |

the code affected is :

BOOST_STATIC_CONSTANT(bits_t, combined_bits = LHS_bits & ~RHS_mask | RHS_bits );

The fix is somehow easy :

BOOST_STATIC_CONSTANT(bits_t, combined_bits = LHS_bits & (~RHS_mask | RHS_bits) );

Attachments (2)

preprocessed.hpp.1 (1.8 KB ) - added by Joel Falcou <joel.falcou@…> 14 years ago.
First pacthed file : boost/function_types/detail/pp_retag_default_cc/preprocessed.hpp
preprocessed.hpp.2 (2.9 KB ) - added by Joel Falcou <joel.falcou@…> 14 years ago.
function_types/detail/pp_tags/preprocessed.hpp

Download all attachments as: .zip

Change History (5)

comment:1 by Joel Falcou <joel.falcou@…>, 14 years ago

Milestone: Boost 1.37.0Boost 1.38.0
Version: Boost 1.36.0Boost 1.37.0

by Joel Falcou <joel.falcou@…>, 14 years ago

Attachment: preprocessed.hpp.1 added

First pacthed file : boost/function_types/detail/pp_retag_default_cc/preprocessed.hpp

by Joel Falcou <joel.falcou@…>, 14 years ago

Attachment: preprocessed.hpp.2 added

function_types/detail/pp_tags/preprocessed.hpp

comment:2 by Joel Falcou <joel.falcou@…>, 14 years ago

Milestone: Boost 1.38.0Boost 1.39.0
Severity: CosmeticProblem
Version: Boost 1.37.0Boost 1.38.0

Adding patched files for reference, in hoep it'll be fixed in 1.39

comment:3 by Andrey Semashev, 13 years ago

Resolution: fixed
Status: newclosed

(In [55872]) Merged patchset 44631 from trunk. Resolves parenthesis warnings on GCC 4.3. Fixes #2321.

Note: See TracTickets for help on using tickets.