Re: [Boost-bugs] [Boost C++ Libraries] #8665: Unreachable code warnings in variant.hpp - msvc

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 11:48:48


#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 apolukhin):

 Replying to [comment:2 hvemha@…]:
> Not sure about the warning on line 1017.
> Only got this when building from the command line: cl /W4 /O2 Test.cpp

 This is the only warning I can reproduce on my visual studio. My previous
 message was about it.[[BR]][[BR]]

> 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.

 Can not reproduce it on visual studio 11. May be it disappears after some
 updates of visual studio? My version is `11.0.60315.01 Update 2`. What's
 yours?[[BR]][[BR]]

> 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.

 Usually all compiler developers require simplified version of code to
 reproduce compiler issue. Such code shall not include additional third
 party headers (`variant.hpp`) and shall contain minimal amount of
 code.[[BR]][[BR]]

> Is it possible to just disable the C4702 warning in the never to be
 called operator()(U&)? It should be OK in this case.

 It is OK if this warning can not be fixed by code modifications. I'm just
 trying to figure out how to reproduce it, does MS know about that issue,
 is that really an issue, how can it be reproduced outside Boost.

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/8665#comment:3>
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