Subject: Re: [Boost-bugs] [Boost C++ Libraries] #8665: Unreachable code warnings in variant.hpp - msvc
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2013-06-07 08:38:09
#8665: Unreachable code warnings in variant.hpp - msvc
-------------------------------+---------------------
Reporter: hvemha@⦠| Owner: ebf
Type: Bugs | Status: new
Milestone: To Be Determined | Component: variant
Version: Boost 1.53.0 | Severity: Problem
Resolution: | Keywords:
-------------------------------+---------------------
Comment (by hvemha@â¦):
Not sure about the warning on line 1017.
Only got this when building from the command line: cl /W4 /O2 Test.cpp
A default C++ project in Visual Studio and only changing the warning level
in release build produces 4 C4702 warnings about line 353 for code.
It is clearly a bug to reach this line. I think it is the return and not
the function all producing the warning. Probably an issue with the
compiler (inline and `__declspec(noreturn)`?).
Also not sure what you mean by without boost::variant? operator< and
operator== instantiates know_get, and this in turn results in the warnings
on line 353.
Is it possible to just disable the C4702 warning in the never to be called
operator()(U&)? It should be OK in this case.
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/8665#comment:2> 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:13 UTC