[clang] [clang-format] Fix a bug in annotating function declaration names (PR #76206)

2024-03-10 Thread Matt Mundell via cfe-commits
mattmundell wrote: Thanks @owenca, I added an argument name instead ([cb983df](https://github.com/greenbone/gvmd/pull/2112/commits/cb983dfada959f0f73bfed7a438e5c79898408d6)). https://github.com/llvm/llvm-project/pull/76206 ___ cfe-commits mailing list

[clang] [clang-format] Fix a bug in annotating function declaration names (PR #76206)

2023-12-22 Thread Matt Mundell via cfe-commits
mattmundell wrote: > `clang-format` doesn't know what are types, except for the keywords. So there > is no way to decide if this is a function declaration without naming the > parameters, or a variable declaration with a constructor call. This is C so I guess it can only be a function declarat

[clang] [clang-format] Fix a bug in annotating function declaration names (PR #76206)

2023-12-22 Thread Matt Mundell via cfe-commits
mattmundell wrote: Thanks for doing this. Does it mean we would have to add every type we use to our config? It would be much more convenient if clang-format treated the argument list the same way as it does for definitions. For example ``` printf "int\niso_time(time_t) { return 1; }\n" | clan