Eugene.Zelenko added inline comments.
================ Comment at: clang-tools-extra/clang-tidy/cppcoreguidelines/AdjacentArgumentsOfSameTypeCheck.cpp:1 +//===--- AvoidAdjacentArgumentsOfSameTypeCheck.cpp - clang-tidy --------------------===// +// ---------------- Please adjust length to 80 characters. ================ Comment at: clang-tools-extra/clang-tidy/cppcoreguidelines/AdjacentArgumentsOfSameTypeCheck.cpp:9 + +#include <string> +#include <utility> ---------------- Please C++ headers aster LLVM ones. ================ Comment at: clang-tools-extra/clang-tidy/cppcoreguidelines/AdjacentArgumentsOfSameTypeCheck.cpp:35 +/// This method attempts to discard everything as much as possible. +const Type *stripType(const Type *T); + ---------------- Functions should be static. Anonymous namespace only for types definitions. ================ Comment at: clang-tools-extra/clang-tidy/cppcoreguidelines/AdjacentArgumentsOfSameTypeCheck.cpp:488 +void AdjacentArgumentsOfSameTypeCheck::registerMatchers(MatchFinder *Finder) { + if (!getLangOpts().CPlusPlus) + return; ---------------- Check seems to be useful for C and probably for Objective-C. ================ Comment at: clang-tools-extra/docs/ReleaseNotes.rst:94 + + This check finds function definitions where arguments of the same type follow + each other directly, making call sites prone to calling the function with ---------------- Please remove //This check//. ================ Comment at: clang-tools-extra/docs/clang-tidy/checks/cppcoreguidelines-avoid-adjacent-arguments-of-same-type.rst:6 + +This check finds function definitions where arguments of the same type follow +each other directly, making call sites prone to calling the function with ---------------- Please remove //This check//. ================ Comment at: clang-tools-extra/docs/clang-tidy/checks/cppcoreguidelines-avoid-adjacent-arguments-of-same-type.rst:56 + diagnostic is emitted. + Defaults to ``3`` for sake of user-friendliness. + Can be any (positive integer) number. ---------------- Please use single back-tick for option values. ================ Comment at: clang-tools-extra/docs/clang-tidy/checks/cppcoreguidelines-avoid-adjacent-arguments-of-same-type.rst:65 + sequence. + If ``0`` (default value), the check assumes such arguments cannot be mixed + up at a potential call site. ---------------- Please use single back-tick for option values. ================ Comment at: clang-tools-extra/docs/clang-tidy/checks/cppcoreguidelines-avoid-adjacent-arguments-of-same-type.rst:125 + const typename vector<T>::element_type & LeftBegin) { /* ... */ } \ No newline at end of file ---------------- Please add new line. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69560/new/ https://reviews.llvm.org/D69560 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits