[Boost-bugs] [Boost C++ Libraries] #9750: iterator_range<T> to iterator_range<T const> & implicit conversion

Subject: [Boost-bugs] [Boost C++ Libraries] #9750: iterator_range<T> to iterator_range<T const> & implicit conversion
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2014-03-06 21:51:06


#9750: iterator_range<T> to iterator_range<T const> & implicit conversion
------------------------------+--------------------------
 Reporter: psiha | Owner: neilgroves
     Type: Feature Requests | Status: new
Milestone: To Be Determined | Component: range
  Version: Boost 1.55.0 | Severity: Optimization
 Keywords: |
------------------------------+--------------------------
 Please add:

 operator iterator_range<T const> /*const*/ & ( ) /*const*/ { return
 reinterpret_cast<iterator_range<T const> /*const*/ &>( *this ); }

 ...as this is more efficient with functions that take iterator_ranges by-
 ref on compilers w/o the SRA optimization (or on ABI boundaries) and,
 AFAICT, should be safe WRT strict-aliasing-rules...

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/9750>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:15 UTC