================
@@ -150,11 +153,26 @@ static void insertComment(Object &Description,
json::Value &Comment,
auto DescriptionIt = Description.find(Key);
if (DescriptionIt == Description.end()) {
- auto CommentsArray = json::Array();
- CommentsArray.push_back(Comment);
- Description[Key] = std::move(CommentsArray);
+ // For FlattenArray mode, if Comment is an array, use it directly
+ if (FlattenArray && Comment.getAsArray()) {
+ Description[Key] = Comment;
----------------
ilovepi wrote:
doesn't this overwrite the exiting comments if the array was already there...
https://github.com/llvm/llvm-project/pull/188739
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits