]> granicus.if.org Git - llvm/commit
[ADT] Zip range adapter
authorMehdi Amini <mehdi.amini@apple.com>
Wed, 19 Oct 2016 18:02:21 +0000 (18:02 +0000)
committerMehdi Amini <mehdi.amini@apple.com>
Wed, 19 Oct 2016 18:02:21 +0000 (18:02 +0000)
commite66ad1c5d9fd0e2a7068d9b92da54d23fc7dda31
tree690464c38a5b939ec69043a1438bf53b2389ab53
parent4c50ebb18ba3e0e2d4726c15186980aeb55cf3b4
[ADT] Zip range adapter

This augments the STLExtras toolset with a zip iterator and range
adapter. Zip comes in two varieties: `zip`, which will zip to the
shortest of the input ranges, and `zip_first`, which limits its
`begin() == end()` checks to just the first range.

Recommit r284035 after MSVC2013 support has been dropped.

Patch by: Bryant Wong <github.com/bryant>

Differential Revision: https://reviews.llvm.org/D23252

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@284623 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/ADT/STLExtras.h
unittests/ADT/IteratorTest.cpp