Boost C++ Libraries: Ticket #9854: boost_program_options.1.55.0.16\lib\native\src\value_semantic.cpp(271): warning C4127: conditional expression is constant https://svn.boost.org/trac10/ticket/9854 <p> Instead of while(1) use for(;;) </p> <div class="wiki-code"><div class="code"><pre><span class="kt">void</span> <span class="n">error_with_option_name</span><span class="o">::</span><span class="n">replace_token</span><span class="p">(</span><span class="k">const</span> <span class="n">string</span><span class="o">&amp;</span> <span class="n">from</span><span class="p">,</span> <span class="k">const</span> <span class="n">string</span><span class="o">&amp;</span> <span class="n">to</span><span class="p">)</span> <span class="k">const</span> <span class="p">{</span> <span class="k">while</span> <span class="p">(</span><span class="mi">1</span><span class="p">)</span> <span class="p">{</span> </pre></div></div> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/9854 Trac 1.4.3 Vladimir Prus Tue, 08 Apr 2014 09:43:29 GMT <link>https://svn.boost.org/trac10/ticket/9854#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/9854#comment:1</guid> <description> <p> For the obvious fix like this, could you make a pull request on github? I think it has "Edit" button that would allow to create such request without any local work at all. </p> <p> And, while we're at it, MSVC is not acting smart here ;-) </p> </description> <category>Ticket</category> </item> <item> <author>nn1436401@…</author> <pubDate>Tue, 08 Apr 2014 10:36:48 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/9854#comment:2 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/9854#comment:2</guid> <description> <p> I see fix here: github.com/boostorg/program_options/blob/develop/src/value_semantic.cpp#L271 </p> <p> What is the reason for not using 'for(;;)' and then there will be no need for #ifdef ? </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Vladimir Prus</dc:creator> <pubDate>Tue, 08 Apr 2014 11:08:16 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/9854#comment:3 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/9854#comment:3</guid> <description> <p> #ifdefing while(1) does not seem reasonable, indeed. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Vladimir Prus</dc:creator> <pubDate>Wed, 09 Apr 2014 10:06:12 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/9854#comment:4 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/9854#comment:4</guid> <description> <p> Fixed in <a class="ext-link" href="https://github.com/boostorg/program_options/commit/37804b54d4ecbeaea770e4f4fce46cc371083c81"><span class="icon">​</span>https://github.com/boostorg/program_options/commit/37804b54d4ecbeaea770e4f4fce46cc371083c81</a> </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Vladimir Prus</dc:creator> <pubDate>Wed, 09 Apr 2014 10:07:54 GMT</pubDate> <title>status changed; resolution set https://svn.boost.org/trac10/ticket/9854#comment:5 https://svn.boost.org/trac10/ticket/9854#comment:5 <ul> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">fixed</span> </li> </ul> Ticket