Boost C++ Libraries: Ticket #220: Inconvinient macro name 'i' makes VisualAssist to confuse https://svn.boost.org/trac10/ticket/220 <pre class="wiki">Boost version 1.30.0 File: type_traits\detail\is_mem_fun_pointer_tester.hpp Macro definition #define i BOOST_PP_FRAME_ITERATION(1) &lt;bla-bla-bla&gt; #undef i i is a common name of a variable. VisualAssist found this macro definition and, in result, * it paints all occurences of i as macro, instead as local variable * it refers to a line of macro definition, instead of a definition of exact variable Environment: MS Visual Studio 6 Visual Assist 6 P.S. I'm sorry if my English is too bad </pre> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/220 Trac 1.4.3 david_abrahams Mon, 15 Dec 2003 17:38:34 GMT <link>https://svn.boost.org/trac10/ticket/220#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/220#comment:1</guid> <description> <pre class="wiki">Logged In: YES user_id=52572 There's not much we can do about VisualAssist. This is their bug, since "i" is subsequently un-defined a few lines later. </pre> </description> <category>Ticket</category> </item> <item> <dc:creator>kodt</dc:creator> <pubDate>Tue, 16 Dec 2003 08:53:14 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/220#comment:2 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/220#comment:2</guid> <description> <pre class="wiki">Logged In: YES user_id=890789 Well, if it's a problem of VisualAssist (in fact, it's a problem of an end user), there is another inconvinience. If one writes some code as follows: #include &lt;complex&gt; #define i std::complex&lt;double&gt;(0.0,1.0) #include &lt;boost/type_traits.hpp&gt; // here i is undefined #include &lt;iostream&gt; main() { std::cout &lt;&lt; i*i &lt;&lt; std::endl; // expect -1 } I believe, boost should be more careful with commonly used identifiers. </pre> </description> <category>Ticket</category> </item> <item> <dc:creator>pavel_kuznetsov</dc:creator> <pubDate>Tue, 16 Dec 2003 09:04:25 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/220#comment:3 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/220#comment:3</guid> <description> <pre class="wiki">Logged In: YES user_id=230164 That's right, it's a bug in Visual Assist. On the other hand it should not take too many efforts to help VA changing the name of the variable in question to something considerably less frequently used. </pre> </description> <category>Ticket</category> </item> <item> <dc:creator>John Maddock</dc:creator> <pubDate>Wed, 16 Mar 2005 17:12:06 GMT</pubDate> <title>status changed https://svn.boost.org/trac10/ticket/220#comment:4 https://svn.boost.org/trac10/ticket/220#comment:4 <ul> <li><strong>status</strong> <span class="trac-field-old">assigned</span> → <span class="trac-field-new">closed</span> </li> </ul> <pre class="wiki">Logged In: YES user_id=14804 I've just committed some patches to cvs that fix this, "i" is no longer used as a macro name inside the type_traits lib. John Maddock. </pre> Ticket