Boost C++ Libraries: Ticket #11855: generic gives problems in C++/CLI https://svn.boost.org/trac10/ticket/11855 <p> it seems that Boost.Filesystem uyses the name 'generic' with clashes with C++/CLI. I know this is not really a bug, but this is very unhandy and probably makes Boost.Filesystem already unusable in these contexts. </p> <p> 1&gt;c:\boost_1_60_0\boost\filesystem\path.hpp(458): error C2059: syntax error : 'generic' </p> <p> There is a link on www (can't paste links since trac reports these as spam): 'Visual Studio 2008 error C2059: syntax error : 'generic' ' </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/11855 Trac 1.4.3 anonymous Thu, 04 Feb 2016 10:50:11 GMT <link>https://svn.boost.org/trac10/ticket/11855#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/11855#comment:1</guid> <description> <p> Any update on this issue, I am also facing same? </p> </description> <category>Ticket</category> </item> <item> <author>Michael Rasmussen <Michael.Rasmussen@…></author> <pubDate>Wed, 10 Feb 2016 15:29:46 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/11855#comment:2 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/11855#comment:2</guid> <description> <p> C++/CLI has an extension called <code>__identifier</code> (See <a class="ext-link" href="https://msdn.microsoft.com/en-us/library/hzc8ytsz.aspx"><span class="icon">​</span>https://msdn.microsoft.com/en-us/library/hzc8ytsz.aspx</a>) that can be used to work around it. Something like the following should work: </p> <pre class="wiki">#ifdef __cplusplus_cli #define generic __identifier(generic) #endif #include &lt;boost/filesystem.hpp&gt; #ifdef __cplusplus_cli #undef generic #endif </pre> </description> <category>Ticket</category> </item> <item> <author>Stefan Mianome <smianome@…></author> <pubDate>Mon, 14 Mar 2016 10:47:55 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/11855#comment:3 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/11855#comment:3</guid> <description> <p> i think it is a bad idea (and unnecessary) to use C++/CLI keywords in boost code. it would be nice if it could be fixed for future boost versions. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Serear</dc:creator> <pubDate>Thu, 28 Apr 2016 13:32:03 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/11855#comment:4 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/11855#comment:4</guid> <description> <p> Is there a fix planned for the next release ? </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Sun, 01 May 2016 09:56:13 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/11855#comment:5 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/11855#comment:5</guid> <description> <p> Facing the same issue here </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Tue, 17 May 2016 18:41:50 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/11855#comment:6 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/11855#comment:6</guid> <description> <p> This is still a problem in boost 1.61.0 when compiling with Visual Studio 2015. Please consider the name generic_path() for this function. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Wed, 12 Oct 2016 15:39:31 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/11855#comment:7 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/11855#comment:7</guid> <description> <p> Generic_path() is a great option. Possible to put in next build? </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Beman Dawes</dc:creator> <pubDate>Wed, 23 Nov 2016 14:38:20 GMT</pubDate> <title>status changed; resolution set https://svn.boost.org/trac10/ticket/11855#comment:8 https://svn.boost.org/trac10/ticket/11855#comment:8 <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> <p> Fixed in develop. Should be in master in time for 1.63.0. </p> <p> The old generic() name is deprecated but still supported. It and other deprecated functions can be turned off by defining BOOST_FILESYSTEM_NO_DEPRECATED. </p> <p> Thanks, </p> <p> --Beman </p> Ticket TomerP <thetomerpeer@…> Tue, 27 Feb 2018 14:51:07 GMT <link>https://svn.boost.org/trac10/ticket/11855#comment:9 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/11855#comment:9</guid> <description> <p> Was this actually fixed? I'm getting the same error with boost 1.64 </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Sat, 12 May 2018 12:48:05 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/11855#comment:10 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/11855#comment:10</guid> <description> <p> Hi, Im having the same problem. If I define BOOST_FILESYSTEM_NO_DEPRECATED the code compiles but then I get a runtime exception when the form is initialized. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Thu, 19 Jul 2018 09:10:12 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/11855#comment:11 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/11855#comment:11</guid> <description> <p> Having this issue with boost 1.67. </p> </description> <category>Ticket</category> </item> </channel> </rss>