gnu /
gcc /
0723ad39020e5b5e90f40ac0673ab34be7c5b4e0 libstdc++: Add always_inline to trivial range access functions
This makes all the [iterator.range] functions always-inline, except the
ones that construct a std::reverse_iterator, as they do a little more
work. They could probably be made always_inline too though, and maybe
the std::reverse_iterator constructor too.
This means that even for -O0 these functions have no runtime overhead
compared with calling a member of the container, or performing pointer
arithmetic for arrays.
libstdc++-v3/ChangeLog:
* include/bits/range_access.h: Add always_inline attribute to
trivial functions.
1 file changed