================
@@ -295,14 +373,20 @@ void ArgumentCommentCheck::checkCallArgs(ASTContext *Ctx,
}
}
- // If the argument comments are missing for literals add them.
- if (Comments.empty() && shouldAddComment(Args[I])) {
+ // If the argument comments are missing for configured argument kinds, add
+ // them.
+ const CommentKind Kind = shouldAddComment(Args[I]);
+ if (Comments.empty() && Kind != CommentKind::None) {
SmallString<32> ArgComment;
- (llvm::Twine("/*") + II->getName() + "=*/").toStringRef(ArgComment);
+ llvm::Twine("/*")
+ .concat(II->getName())
+ .concat("=*/")
+ .toStringRef(ArgComment);
----------------
vbvictor wrote:
Why we needed to change this line? It seemed perfectly fine in the first place.
There were other occurances.
Can we rollback Twine changes?
https://github.com/llvm/llvm-project/pull/180408
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits