[PATCH] Add clang-tidy check to remove redundant .get() calls on smart pointers.

Samuel Benzaquen sbenza at google.com
Tue Mar 25 10:36:59 PDT 2014


Hi alexfh,

This check finds and removes redundant .get() calls on smart pointers.
Example:
  ptr.get()->Foo()   ==>   ptr->Foo()

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

Files:
  clang-tidy/misc/CMakeLists.txt
  clang-tidy/misc/MiscTidyModule.cpp
  clang-tidy/misc/RedundantSmartptrGet.cpp
  clang-tidy/misc/RedundantSmartptrGet.h
  test/clang-tidy/redundant-smartptr-get-fix.cpp
  test/clang-tidy/redundant-smartptr-get.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D3186.1.patch
Type: text/x-patch
Size: 9300 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20140325/8cdf6c3b/attachment.bin>


More information about the cfe-commits mailing list