[PATCH] D22725: [clang-tidy] Add check 'misc-replace-memcpy'

Jonas Devlieghere via cfe-commits cfe-commits at lists.llvm.org
Sun Jul 24 13:55:16 PDT 2016


JDevlieghere added a comment.

In https://reviews.llvm.org/D22725#494167, @Prazek wrote:

> hmm It seems that I mislead you, I suck at C api - memmove source and destination can overlap, but std::move can't. So I guess you have to remove the memmove support. Sorry.


No problem, I wasn't aware of the issue either, so thanks for letting me know!

While running my check on the LLVM repo I ran into another issue: can't do pointer arithmetic when the arguments to memcpy are void pointers. I will look into updating my matchers to exclude this particular case.


https://reviews.llvm.org/D22725





More information about the cfe-commits mailing list