xref: /llvm-project/clang-tools-extra/clang-tidy/google/DefaultArgumentsCheck.h (revision 4718da506091a37ca4863d979bc541e359b79b10)
111726686SHaojian Wu //===--- DefaultArgumentsCheck.h - clang-tidy--------------------*- C++ -*-===//
211726686SHaojian Wu //
32946cd70SChandler Carruth // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
42946cd70SChandler Carruth // See https://llvm.org/LICENSE.txt for license information.
52946cd70SChandler Carruth // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
611726686SHaojian Wu //
711726686SHaojian Wu //===----------------------------------------------------------------------===//
811726686SHaojian Wu 
911726686SHaojian Wu #ifndef LLVM_CLANG_TOOLS_EXTRA_CLANG_TIDY_GOOGLE_DEFAULT_ARGUMENTS_H
1011726686SHaojian Wu #define LLVM_CLANG_TOOLS_EXTRA_CLANG_TIDY_GOOGLE_DEFAULT_ARGUMENTS_H
1111726686SHaojian Wu 
12478fc5c8SAlexander Kornienko #include "../ClangTidyCheck.h"
1311726686SHaojian Wu 
14*4718da50SCarlos Galvez namespace clang::tidy::google {
1511726686SHaojian Wu 
1611726686SHaojian Wu /// Checks that default parameters are not given for virtual methods.
1711726686SHaojian Wu ///
1811726686SHaojian Wu /// See https://google.github.io/styleguide/cppguide.html#Default_Arguments
1937558fd2SAlexander Kornienko ///
2037558fd2SAlexander Kornienko /// For the user-facing documentation see:
216e566bc5SRichard /// http://clang.llvm.org/extra/clang-tidy/checks/google/default-arguments.html
2211726686SHaojian Wu class DefaultArgumentsCheck : public ClangTidyCheck {
2311726686SHaojian Wu public:
DefaultArgumentsCheck(StringRef Name,ClangTidyContext * Context)2411726686SHaojian Wu   DefaultArgumentsCheck(StringRef Name, ClangTidyContext *Context)
2511726686SHaojian Wu       : ClangTidyCheck(Name, Context) {}
2611726686SHaojian Wu   void registerMatchers(ast_matchers::MatchFinder *Finder) override;
2711726686SHaojian Wu   void check(const ast_matchers::MatchFinder::MatchResult &Result) override;
2811726686SHaojian Wu };
2911726686SHaojian Wu 
30*4718da50SCarlos Galvez } // namespace clang::tidy::google
3111726686SHaojian Wu 
3211726686SHaojian Wu #endif // LLVM_CLANG_TOOLS_EXTRA_CLANG_TIDY_GOOGLE_DEFAULT_ARGUMENTS_H
33