[PATCH] D67647: [Consumed] Refactor handleCall to take function argument list. NFC.

Nicholas Allegra via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Sep 18 17:22:17 PDT 2019


comex updated this revision to Diff 220771.
comex added a comment.
Herald added subscribers: llvm-commits, dexonsmith.
Herald added a project: LLVM.

Here's a new version of the patch that uses iterator ranges instead of `ArrayRef`, to avoid adding new uses of `CallExpr::getArgs()` in case it has to be removed in the future due to the strict aliasing issue.

To support this, the following additional changes are included:

- Fix `CastIterator`'s use of `iterator_adaptor_base` so that `operator[]` isn't broken.

- Add an `operator[]` implementation to `iterator_range`.

- Improve the existing `llvm::drop_begin` helper to assert that it doesn't go out of bounds.  (The implementation would be a lot less ugly if we could use C++17 features; oh well.)


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D67647/new/

https://reviews.llvm.org/D67647

Files:
  clang/include/clang/AST/Stmt.h
  clang/lib/Analysis/Consumed.cpp
  llvm/include/llvm/ADT/iterator_range.h

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D67647.220771.patch
Type: text/x-patch
Size: 6741 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190919/5c0fe38e/attachment-0001.bin>


More information about the cfe-commits mailing list