[clang] 7702023 - [clang-format][NFC] Rename `kind` to `Kind`
Owen Pan via cfe-commits
cfe-commits at lists.llvm.org
Fri Apr 5 22:18:02 PDT 2024
Author: Owen Pan
Date: 2024-04-05T22:17:50-07:00
New Revision: 770202343ebce1f2bc0745c78e298e251f204bee
URL: https://github.com/llvm/llvm-project/commit/770202343ebce1f2bc0745c78e298e251f204bee
DIFF: https://github.com/llvm/llvm-project/commit/770202343ebce1f2bc0745c78e298e251f204bee.diff
LOG: [clang-format][NFC] Rename `kind` to `Kind`
Added:
Modified:
clang/lib/Format/UnwrappedLineParser.cpp
Removed:
################################################################################
diff --git a/clang/lib/Format/UnwrappedLineParser.cpp b/clang/lib/Format/UnwrappedLineParser.cpp
index 55c627d87f08b5..57d8dbcf3b4c77 100644
--- a/clang/lib/Format/UnwrappedLineParser.cpp
+++ b/clang/lib/Format/UnwrappedLineParser.cpp
@@ -365,11 +365,11 @@ bool UnwrappedLineParser::parseLevel(const FormatToken *OpeningBrace,
nextToken();
continue;
}
- tok::TokenKind kind = FormatTok->Tok.getKind();
+ tok::TokenKind Kind = FormatTok->Tok.getKind();
if (FormatTok->getType() == TT_MacroBlockBegin)
- kind = tok::l_brace;
+ Kind = tok::l_brace;
else if (FormatTok->getType() == TT_MacroBlockEnd)
- kind = tok::r_brace;
+ Kind = tok::r_brace;
auto ParseDefault = [this, OpeningBrace, IfKind, &IfLBrace, &HasDoWhile,
&HasLabel, &StatementCount] {
@@ -380,7 +380,7 @@ bool UnwrappedLineParser::parseLevel(const FormatToken *OpeningBrace,
assert(StatementCount > 0 && "StatementCount overflow!");
};
- switch (kind) {
+ switch (Kind) {
case tok::comment:
nextToken();
addUnwrappedLine();
@@ -3280,8 +3280,8 @@ void UnwrappedLineParser::parseSwitch() {
}
// Operators that can follow a C variable.
-static bool isCOperatorFollowingVar(tok::TokenKind kind) {
- switch (kind) {
+static bool isCOperatorFollowingVar(tok::TokenKind Kind) {
+ switch (Kind) {
case tok::ampamp:
case tok::ampequal:
case tok::arrow:
More information about the cfe-commits
mailing list