[PATCH] D130470: [clang][analyzer] Add more wide-character functions to CStringChecker
Balázs Kéri via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Jul 29 01:32:38 PDT 2022
balazske added inline comments.
================
Comment at: clang/lib/StaticAnalyzer/Checkers/CStringChecker.cpp:136-137
{{CDF_MaybeBuiltin, "memcpy", 3},
- std::bind(&CStringChecker::evalMemcpy, _1, _2, _3, false)},
+ std::bind(&CStringChecker::evalMemcpy, _1, _2, _3,
+ CharacterKind::Regular)},
{{CDF_MaybeBuiltin, "wmemcpy", 3},
----------------
steakhal wrote:
> If you were using a plain-old enum, it would feel less repetitive.
> You are already in the anonymous namespace, so it would not pollute anything anyway.
> You could also `use std::bind`, to make it denser.
Every other enum in the file is `enum class`, I like more to use enum class. But the name can be shortened and constants added because it is used often.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D130470/new/
https://reviews.llvm.org/D130470
More information about the cfe-commits
mailing list