clang 20.0.0git
CheckerHelpers.cpp
Go to the documentation of this file.
1//===---- CheckerHelpers.cpp - Helper functions for checkers ----*- C++ -*-===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8//
9// This file defines several static functions for use in checkers.
10//
11//===----------------------------------------------------------------------===//
12
14#include "clang/AST/Decl.h"
15#include "clang/AST/Expr.h"
18#include <optional>
19
20namespace clang {
21
22namespace ento {
23
24// Recursively find any substatements containing macros
25bool containsMacro(const Stmt *S) {