[PATCH] D130906: [clang] format string checking for conpile-time evaluated str literal
Aaron Ballman via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Aug 4 06:31:24 PDT 2022
aaron.ballman added a comment.
In D130906#3699361 <https://reviews.llvm.org/D130906#3699361>, @inclyc wrote:
> Last question, issue https://github.com/llvm/llvm-project/issues/55805 mentioned another case, some `initListExpr` evaulated as "StringLiteral"(`Array` in fact, but maybe able to consider as a literal), should we implement this?
Yes, I think we should. The following are functionally equivalent:
static constexpr const char *str1 = "%s";
static constexpr const char str2[] = { '%', 's', 0 };
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D130906/new/
https://reviews.llvm.org/D130906
More information about the cfe-commits
mailing list