[clang] [clang-format] Add an option for editing enum trailing commas (PR #133576)

Björn Schäpers via cfe-commits cfe-commits at lists.llvm.org
Sun Mar 30 08:26:53 PDT 2025


================
@@ -2214,6 +2214,21 @@ FormatStyle::GetLanguageStyle(FormatStyle::LanguageKind Language) const {
 
 namespace {
 
+void replaceToken(const FormatToken &Token, FormatToken *Next,
+                  const SourceManager &SourceMgr, tooling::Replacements &Result,
+                  const char *Text = "") {
----------------
HazardyKnusperkeks wrote:

This is a local function and we use it with string literals. And if I looked correctly `tooling::Replacement` takes an `StringRef`.

https://github.com/llvm/llvm-project/pull/133576


More information about the cfe-commits mailing list