[clang-tidy] safety-no-assembler
Summary:
Add a new clang-tidy module for safety-critical checks.
Include a check for inline assembler.
Reviewers: Prazek, dtarditi, malcolm.parsons, alexfh, aaron.ballman, idlecode
Reviewed By: idlecode
Subscribers: idlecode, JonasToth, Eugene.Zelenko, mgorny, JDevlieghere, cfe-commits
Tags: #clang-tools-extra
Differential Revision: https://reviews.llvm.org/D29267
llvm-svn: 294255
2017-02-07 06:57:14 +08:00
|
|
|
//===--- NoAssemblerCheck.h - clang-tidy-------------------------*- C++ -*-===//
|
|
|
|
//
|
2019-01-19 16:50:56 +08:00
|
|
|
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
|
|
|
|
// See https://llvm.org/LICENSE.txt for license information.
|
|
|
|
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
|
[clang-tidy] safety-no-assembler
Summary:
Add a new clang-tidy module for safety-critical checks.
Include a check for inline assembler.
Reviewers: Prazek, dtarditi, malcolm.parsons, alexfh, aaron.ballman, idlecode
Reviewed By: idlecode
Subscribers: idlecode, JonasToth, Eugene.Zelenko, mgorny, JDevlieghere, cfe-commits
Tags: #clang-tools-extra
Differential Revision: https://reviews.llvm.org/D29267
llvm-svn: 294255
2017-02-07 06:57:14 +08:00
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
2017-03-20 01:23:23 +08:00
|
|
|
#ifndef LLVM_CLANG_TOOLS_EXTRA_CLANG_TIDY_HICPP_NO_ASSEMBLER_H
|
|
|
|
#define LLVM_CLANG_TOOLS_EXTRA_CLANG_TIDY_HICPP_NO_ASSEMBLER_H
|
[clang-tidy] safety-no-assembler
Summary:
Add a new clang-tidy module for safety-critical checks.
Include a check for inline assembler.
Reviewers: Prazek, dtarditi, malcolm.parsons, alexfh, aaron.ballman, idlecode
Reviewed By: idlecode
Subscribers: idlecode, JonasToth, Eugene.Zelenko, mgorny, JDevlieghere, cfe-commits
Tags: #clang-tools-extra
Differential Revision: https://reviews.llvm.org/D29267
llvm-svn: 294255
2017-02-07 06:57:14 +08:00
|
|
|
|
|
|
|
#include "../ClangTidy.h"
|
|
|
|
|
|
|
|
namespace clang {
|
|
|
|
namespace tidy {
|
2017-03-20 01:23:23 +08:00
|
|
|
namespace hicpp {
|
[clang-tidy] safety-no-assembler
Summary:
Add a new clang-tidy module for safety-critical checks.
Include a check for inline assembler.
Reviewers: Prazek, dtarditi, malcolm.parsons, alexfh, aaron.ballman, idlecode
Reviewed By: idlecode
Subscribers: idlecode, JonasToth, Eugene.Zelenko, mgorny, JDevlieghere, cfe-commits
Tags: #clang-tools-extra
Differential Revision: https://reviews.llvm.org/D29267
llvm-svn: 294255
2017-02-07 06:57:14 +08:00
|
|
|
|
|
|
|
/// Find assembler statements. No fix is offered.
|
|
|
|
///
|
|
|
|
/// For the user-facing documentation see:
|
2017-03-20 01:23:23 +08:00
|
|
|
/// http://clang.llvm.org/extra/clang-tidy/checks/hicpp-no-assembler.html
|
[clang-tidy] safety-no-assembler
Summary:
Add a new clang-tidy module for safety-critical checks.
Include a check for inline assembler.
Reviewers: Prazek, dtarditi, malcolm.parsons, alexfh, aaron.ballman, idlecode
Reviewed By: idlecode
Subscribers: idlecode, JonasToth, Eugene.Zelenko, mgorny, JDevlieghere, cfe-commits
Tags: #clang-tools-extra
Differential Revision: https://reviews.llvm.org/D29267
llvm-svn: 294255
2017-02-07 06:57:14 +08:00
|
|
|
class NoAssemblerCheck : public ClangTidyCheck {
|
|
|
|
public:
|
|
|
|
NoAssemblerCheck(StringRef Name, ClangTidyContext *Context)
|
|
|
|
: ClangTidyCheck(Name, Context) {}
|
|
|
|
void registerMatchers(ast_matchers::MatchFinder *Finder) override;
|
|
|
|
void check(const ast_matchers::MatchFinder::MatchResult &Result) override;
|
|
|
|
};
|
|
|
|
|
2017-03-20 01:23:23 +08:00
|
|
|
} // namespace hicpp
|
[clang-tidy] safety-no-assembler
Summary:
Add a new clang-tidy module for safety-critical checks.
Include a check for inline assembler.
Reviewers: Prazek, dtarditi, malcolm.parsons, alexfh, aaron.ballman, idlecode
Reviewed By: idlecode
Subscribers: idlecode, JonasToth, Eugene.Zelenko, mgorny, JDevlieghere, cfe-commits
Tags: #clang-tools-extra
Differential Revision: https://reviews.llvm.org/D29267
llvm-svn: 294255
2017-02-07 06:57:14 +08:00
|
|
|
} // namespace tidy
|
|
|
|
} // namespace clang
|
|
|
|
|
2017-03-20 01:23:23 +08:00
|
|
|
#endif // LLVM_CLANG_TOOLS_EXTRA_CLANG_TIDY_HICPP_NO_ASSEMBLER_H
|