[PATCH] D39855: [ADT] Rewrite mapped_iterator in terms of iterator_adaptor_base.

Lang Hames via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Nov 9 11:25:58 PST 2017


lhames created this revision.
Herald added a subscriber: mgorny.

This eliminates the boilerplate implementation of the iterator interface in
mapped_iterator.

This patch also adds unit tests that verify that the mapped function is applied
by operator* and operator->, and that references returned by the map function
are returned via operator*.


https://reviews.llvm.org/D39855

Files:
  include/llvm/ADT/STLExtras.h
  unittests/ADT/CMakeLists.txt
  unittests/ADT/MappedIteratorTest.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D39855.122284.patch
Type: text/x-patch
Size: 5667 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20171109/2525dff3/attachment.bin>


More information about the llvm-commits mailing list