JonasToth added inline comments.
================ Comment at: clang-tidy/bugprone/BranchCloneCheck.cpp:31 +/// an if/else if/else chain is one statement (which may be a CompoundStmt). +using SwitchBranch = llvm::SmallVector<const Stmt *, 2>; +} // anonymous namespace ---------------- donat.nagy wrote: > JonasToth wrote: > > maybe plural for the typename would fit better, as its a vector of multiple > > elements? > This type represents one branch in a switch statement (which consists of > multiple statements). I cannot think of a descriptive, short name which also > happens to be plural and I do not want to use a monstrosity like > `StatementsInSwitchBranch`. > > By the way, can anyone think of shorter, but still clear names for > `areStatementsIdentical()` and `areSwitchBranchesIdentical()` ? The name is ok, I missunderstood the sense of the type. Your other names are fine i think. Repository: rCTE Clang Tools Extra CHANGES SINCE LAST ACTION https://reviews.llvm.org/D54757/new/ https://reviews.llvm.org/D54757 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits