Opened 13 years ago
Closed 13 years ago
#3556 closed Bugs (fixed)
Missing explicit braces to avoid ambiguous else clause
Reported by: | Owned by: | Vladimir Prus | |
---|---|---|---|
Milestone: | Boost 1.41.0 | Component: | program_options |
Version: | Boost Development Trunk | Severity: | Cosmetic |
Keywords: | Cc: |
Description
While building Boost from current trunk (r57126) using GCC 4.4.1 I'm getting the following warning for Boost Program Options:
gcc.compile.c++ bin.v2/libs/program_options/build/gcc-4.4.1/release/link-static/threading-multi/options_description.o libs/program_options/src/options_description.cpp: In member function ‘boost::program_options::option_description::match_result boost::program_options::option_description::match(const std::string&, bool) const’: libs/program_options/src/options_description.cpp:74: warning: suggest explicit braces to avoid ambiguous ‘else
Patch adding the extra braces attached.
Attachments (1)
Change History (3)
by , 13 years ago
Attachment: | program_options-explicit-braces.patch added |
---|
comment:1 by , 13 years ago
By the way, one more warning is reported. To not to make too much noise with new ticket, here it is:
libs/program_options/src/value_semantic.cpp:175: warning: suggest parentheses around ‘&&’ within ‘||’ libs/program_options/src/value_semantic.cpp:190: warning: suggest parentheses around ‘&&’ within ‘||
comment:2 by , 13 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Note:
See TracTickets
for help on using tickets.
Patch with missing braces to avoid ambiguous else clause