[clang] Update Catch missing format attributes (PR #106649)

2024-08-30 Thread Budimir Aranđelović via cfe-commits
@@ -5416,15 +5416,18 @@ Sema::GetMissingFormatAttributes(Stmt *Body, const FunctionDecl *FDecl) { // If child expression is function, check if it is format function. // If it is, check if parent function misses format attributes. +unsigned int ChildFunctionFormatA

[clang] Update Catch missing format attributes (PR #106649)

2024-08-30 Thread Budimir Aranđelović via cfe-commits
@@ -387,17 +388,6 @@ void f40(char *out, ... /* args */) // #f40 void f41(char *out, ... /* args */) // #f41 { va_list args; -char *ch; -vscanf("%s", ch); budimirarandjelovichtec wrote: Char * was passed to second parameter which accepts va_list ty

[clang] Update Catch missing format attributes (PR #106649)

2024-08-30 Thread Budimir Aranđelović via cfe-commits
@@ -84,16 +81,16 @@ void f7(const char *out, ... /* args */) // #f7 { va_list args; -vscanf(out, &args[0]); // expected-warning@#f7 {{diagnostic behavior may be improved by adding the 'scanf' format attribute to the declaration of 'f7'}} - //

[clang] Update Catch missing format attributes (PR #106649)

2024-08-30 Thread Budimir Aranđelović via cfe-commits
https://github.com/budimirarandjelovichtec edited https://github.com/llvm/llvm-project/pull/106649 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Update Catch missing format attributes (PR #106649)

2024-08-30 Thread Budimir Aranđelović via cfe-commits
@@ -5506,16 +5509,13 @@ Sema::GetMissingFormatAttributes(Stmt *Body, const FunctionDecl *FDecl) { } // Get first argument index -unsigned FirstToCheck = [&]() -> unsigned { +int FirstToCheck = [&]() -> unsigned { if (!FDecl->isVariadic()) retur

[clang] Update Catch missing format attributes (PR #106649)

2024-08-30 Thread Budimir Aranđelović via cfe-commits
https://github.com/budimirarandjelovichtec commented: Here are major changes. https://github.com/llvm/llvm-project/pull/106649 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Update Catch missing format attributes (PR #106649)

2024-08-29 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Vitaly Buka (vitalybuka) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/106649.diff 2 Files Affected: - (modified) clang/lib/Sema/SemaDeclAttr.cpp (+14-14) - (modified) clang/test/Sema/attr-format-missing.c (+27-37)

[clang] Update Catch missing format attributes (PR #106649)

2024-08-29 Thread Vitaly Buka via cfe-commits
https://github.com/vitalybuka converted_to_draft https://github.com/llvm/llvm-project/pull/106649 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Update Catch missing format attributes (PR #106649)

2024-08-29 Thread Vitaly Buka via cfe-commits
https://github.com/vitalybuka created https://github.com/llvm/llvm-project/pull/106649 None >From 46f3fb6634138f2d9ce8f301b05d09d16da9f3ea Mon Sep 17 00:00:00 2001 From: Vitaly Buka Date: Thu, 29 Aug 2024 17:43:18 -0700 Subject: [PATCH] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20initia