[PATCH] Use 'auto const&' for iterators whose deref operator returns a const var

Ariel Bernal ariel.j.bernal at intel.com
Tue May 7 11:39:36 PDT 2013


Hi revane,

This patch is based on http://llvm-reviews.chandlerc.com/D641 by Tareq.

- This patch fixes Bugzilla: PR15601
- Added check for whether the loop variable and the variable's initializer have the same type.
- Added and fixed tests.

http://llvm-reviews.chandlerc.com/D759

Files:
  cpp11-migrate/LoopConvert/LoopActions.cpp
  cpp11-migrate/LoopConvert/LoopActions.h
  cpp11-migrate/LoopConvert/LoopMatchers.cpp
  cpp11-migrate/LoopConvert/LoopMatchers.h
  test/cpp11-migrate/LoopConvert/Inputs/structures.h
  test/cpp11-migrate/LoopConvert/iterator.cpp
  test/cpp11-migrate/LoopConvert/naming-conflict.cpp
  test/cpp11-migrate/LoopConvert/nesting.cpp
  test/cpp11-migrate/LoopConvert/single-iterator.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D759.1.patch
Type: text/x-patch
Size: 16541 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20130507/ad5aeec8/attachment.bin>


More information about the cfe-commits mailing list