Boost C++ Libraries: Ticket #2343: [exception] Patch to improve support of CodeGear C++Builder 2009 https://svn.boost.org/trac10/ticket/2343 <p> The attached patch fixes workarounds for the latest <a class="missing wiki">CodeGear</a> (ex Borland) compiler. </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/2343 Trac 1.4.3 Nicola Musatti Thu, 18 Sep 2008 22:21:55 GMT attachment set https://svn.boost.org/trac10/ticket/2343 https://svn.boost.org/trac10/ticket/2343 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">boost_exception.patch</span> </li> </ul> Ticket Emil Dotchevski Thu, 18 Sep 2008 22:38:21 GMT <link>https://svn.boost.org/trac10/ticket/2343#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2343#comment:1</guid> <description> <p> With this patch applied, what is the status of the tests from libs/exception/test on <a class="missing wiki">CodeGear</a>? </p> <p> If those tests don't pass, then instead of this patch, boost/throw_exception.hpp should be modified to disable Boost Exception on this compiler, by implicitly defining BOOST_EXCEPTION_DISABLE just like it is currently done for MSVC &lt; 7.1 and BCC. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Nicola Musatti</dc:creator> <pubDate>Thu, 18 Sep 2008 22:46:35 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2343#comment:2 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2343#comment:2</guid> <description> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/2343#comment:1" title="Comment 1">emildotchevski</a>: </p> <blockquote class="citation"> <p> With this patch applied, what is the status of the tests from libs/exception/test on <a class="missing wiki">CodeGear</a>? </p> <p> If those tests don't pass, then instead of this patch, boost/throw_exception.hpp should be modified to disable Boost Exception on this compiler, by implicitly defining BOOST_EXCEPTION_DISABLE just like it is currently done for MSVC &lt; 7.1 and BCC. </p> </blockquote> <p> My current results show 9 failures for <a class="missing wiki">CodeGear</a>'s 6.1.0 and 18 failures for the last Borland release, 5.9.3 . I can't say at this time whether there's any hope for improvement. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Emil Dotchevski</dc:creator> <pubDate>Thu, 18 Sep 2008 23:04:28 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2343#comment:3 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2343#comment:3</guid> <description> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/2343#comment:2" title="Comment 2">nmusatti</a>: </p> <blockquote class="citation"> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/2343#comment:1" title="Comment 1">emildotchevski</a>: </p> <blockquote class="citation"> <p> With this patch applied, what is the status of the tests from libs/exception/test on <a class="missing wiki">CodeGear</a>? </p> <p> If those tests don't pass, then instead of this patch, boost/throw_exception.hpp should be modified to disable Boost Exception on this compiler, by implicitly defining BOOST_EXCEPTION_DISABLE just like it is currently done for MSVC &lt; 7.1 and BCC. </p> </blockquote> <p> My current results show 9 failures for <a class="missing wiki">CodeGear</a>'s 6.1.0 and 18 failures for the last Borland release, 5.9.3 . I can't say at this time whether there's any hope for improvement. </p> </blockquote> <p> My gut feeling tells me that there isn't hope for improvement, but you're welcome to give it a try. </p> <p> Otherwise, let me know how to detect <a class="missing wiki">CodeGear</a> 6.1.0 in boost/throw_exception.hpp (or you can directly post a patch for boost/throw_exception.hpp that #defines BOOST_EXCEPTION_DISABLE on <a class="missing wiki">CodeGear</a>.) </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Nicola Musatti</dc:creator> <pubDate>Sat, 20 Sep 2008 13:31:01 GMT</pubDate> <title>attachment set https://svn.boost.org/trac10/ticket/2343 https://svn.boost.org/trac10/ticket/2343 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">boost_exception2.patch</span> </li> </ul> Ticket Nicola Musatti Sat, 20 Sep 2008 13:31:12 GMT attachment set https://svn.boost.org/trac10/ticket/2343 https://svn.boost.org/trac10/ticket/2343 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">exception_ptr.patch</span> </li> </ul> Ticket Nicola Musatti Sat, 20 Sep 2008 13:31:26 GMT attachment set https://svn.boost.org/trac10/ticket/2343 https://svn.boost.org/trac10/ticket/2343 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">libs_exception.patch</span> </li> </ul> Ticket Nicola Musatti Sat, 20 Sep 2008 13:39:48 GMT <link>https://svn.boost.org/trac10/ticket/2343#comment:4 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2343#comment:4</guid> <description> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/2343#comment:3" title="Comment 3">emildotchevski</a>: </p> <blockquote class="citation"> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/2343#comment:2" title="Comment 2">nmusatti</a>: </p> <blockquote class="citation"> <p> My current results show 9 failures for <a class="missing wiki">CodeGear</a>'s 6.1.0 and 18 failures for the last Borland release, 5.9.3 . I can't say at this time whether there's any hope for improvement. </p> </blockquote> <p> My gut feeling tells me that there isn't hope for improvement, but you're welcome to give it a try. </p> <p> Otherwise, let me know how to detect <a class="missing wiki">CodeGear</a> 6.1.0 in boost/throw_exception.hpp (or you can directly post a patch for boost/throw_exception.hpp that #defines BOOST_EXCEPTION_DISABLE on <a class="missing wiki">CodeGear</a>.) </p> </blockquote> <p> With the updated patches I just uploaded the failures go down to 5 for <a class="missing wiki">CodeGear</a>. </p> <p> As it is I'd prefer these patches to be applied rather than have the library disabled, so as to pinpoint the remaining problems. Should we get requests to the contrary from users it wouldn't be too complicated to backout. </p> <p> Note that I have commit rights so I can help with actually applying the changes. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Peter Dimov</dc:creator> <pubDate>Sat, 20 Sep 2008 15:42:49 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2343#comment:5 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2343#comment:5</guid> <description> <p> With regards to </p> <p> <code>return typename exception_detail::enable_error_info_return_type&lt;T&gt;::type(x);</code> </p> <p> I'd suggest </p> <pre class="wiki">typedef typename exception_detail::enable_error_info_return_type&lt;T&gt;::type Rt; return Rt(x); </pre><p> instead of yet another config macro. </p> <p> Also, &lt;string.h&gt; should have a ::memcpy, why would one need to use the std:: one? </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Nicola Musatti</dc:creator> <pubDate>Sat, 20 Sep 2008 17:07:01 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2343#comment:6 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2343#comment:6</guid> <description> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/2343#comment:5" title="Comment 5">pdimov</a>: </p> <blockquote class="citation"> <p> With regards to </p> <p> <code>return typename exception_detail::enable_error_info_return_type&lt;T&gt;::type(x);</code> </p> <p> I'd suggest </p> <pre class="wiki">typedef typename exception_detail::enable_error_info_return_type&lt;T&gt;::type Rt; return Rt(x); </pre><p> instead of yet another config macro. </p> </blockquote> <p> Well, the config macro is already there and its use documents the presence of a workaround, but I agree that your approach is cleaner. Anyway, I have no strong opinion either way. Emil, let me know which approach you prefer. </p> <blockquote class="citation"> <p> Also, &lt;string.h&gt; should have a ::memcpy, why would one need to use the std:: one? </p> </blockquote> <p> That's the bug for which I'm providing that workaround. The definition in the global namespace isn't seen by the compiler. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Emil Dotchevski</dc:creator> <pubDate>Mon, 22 Sep 2008 18:37:43 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2343#comment:7 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2343#comment:7</guid> <description> <p> nmusatti, Trunk revision 48918 should address all issues but please test with <a class="missing wiki">CodeGear</a> because my changes differ from your patch. Thanks for helping with this and thanks to Peter Dimov for the typedef suggestion. </p> <p> I did not put in your workarounds for libs/exception/test because I wanted you to try them without defining the tag types. For example, intead of: </p> <pre class="wiki">13 #if BOOST_WORKAROUND(__CODEGEARC__, BOOST_TESTED_AT(0x610)) 14 struct my_tag {}; 15 #endif </pre><p> could you try: </p> <pre class="wiki">13 #if BOOST_WORKAROUND(__CODEGEARC__, BOOST_TESTED_AT(0x610)) 14 struct my_tag; 15 #endif </pre><p> Thanks, Emil </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Mon, 22 Sep 2008 19:57:59 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2343#comment:8 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2343#comment:8</guid> <description> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/2343#comment:7" title="Comment 7">emildotchevski</a>: </p> <blockquote class="citation"> <p> nmusatti, Trunk revision 48918 should address all issues but please test with <a class="missing wiki">CodeGear</a> because my changes differ from your patch. Thanks for helping with this and thanks to Peter Dimov for the typedef suggestion. </p> </blockquote> <p> Your changes work; all relevant tests still pass. </p> <blockquote class="citation"> <p> I did not put in your workarounds for libs/exception/test because I wanted you to try them without defining the tag types. For example, intead of: </p> <pre class="wiki">13 #if BOOST_WORKAROUND(__CODEGEARC__, BOOST_TESTED_AT(0x610)) 14 struct my_tag {}; 15 #endif </pre><p> could you try: </p> <pre class="wiki">13 #if BOOST_WORKAROUND(__CODEGEARC__, BOOST_TESTED_AT(0x610)) 14 struct my_tag; 15 #endif </pre></blockquote> <p> Unfortunately just declaring the tag structs isn't enough; tests fail with linker errors. </p> <p> Cheers, Nicola </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Emil Dotchevski</dc:creator> <pubDate>Mon, 22 Sep 2008 22:55:23 GMT</pubDate> <title>status changed; resolution set https://svn.boost.org/trac10/ticket/2343#comment:9 https://svn.boost.org/trac10/ticket/2343#comment:9 <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