Boost C++ Libraries: Ticket #6614: Start adapting Quaternions and Octonions for C++11 https://svn.boost.org/trac10/ticket/6614 <p> When I read up on C++11 features like <code>constexpr</code> and <code>noexcept</code>, I wonder what classes in Boost can be adapted for them. The quaternion and octonion class templates represent value-types that can easily be made <code>constexpr</code> compliant. Further, the specializations for the built-in floating-point types can be made <code>noexcept</code> for their operations. I have a patch that starts work on both fronts. </p> <p> Since the library is implemented with macro madness, I can't change too much without making the file unrecognizable to <code>diff</code> utilities. This means that some stuff in the specializations that could be <code>noexcept</code> can't be since they share textual implementation with the general templates' versions of the code. </p> <p> Some aggresive marking of constructors as <code>explicit</code> has been toned down, still conforming to the docs. Speaking of which, they have been changed to match the new code (plus two doc errors). </p> <p> For future directions, the big hurdle is the idiom that binary-operator @@ is implemented in terms of @@=. That's generally OK in C++03, but now it disqualifies the former from being declared <code>constexpr</code> since the latter is mutating. Fixing this would entail flipping the relationship between the functions around. </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/6614 Trac 1.4.3 Daryle Walker Sat, 25 Feb 2012 01:29:42 GMT attachment set https://svn.boost.org/trac10/ticket/6614 https://svn.boost.org/trac10/ticket/6614 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">quaternion_cpp11.diff</span> </li> </ul> <p> Changes for C++11 adaptation </p> Ticket