blob: eff0ec029a4d1984e1647aa76a0f8ebb740b365e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
//===-- UseAutoMatchers.h - Matchers for use-auto transform -----*- C++ -*-===//
//
// The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
///
/// \file
/// \brief This file contains the declarations for matcher-generating functions
/// and names for bound nodes found by AST matchers.
///
//===----------------------------------------------------------------------===//
#ifndef CLANG_MODERNIZE_USE_AUTO_MATCHERS_H
#define CLANG_MODERNIZE_USE_AUTO_MATCHERS_H
#include "clang/ASTMatchers/ASTMatchers.h"
extern const char *IteratorDeclStmtId;
extern const char *DeclWithNewId;
extern const char *NewExprId;
/// \brief Create a matcher that matches declaration staments that have
/// variable declarations where the type is an iterator for an std container
/// and has an explicit initializer of the same type.
clang::ast_matchers::StatementMatcher makeIteratorDeclMatcher();
/// \brief Create a matcher that matches variable declarations that are
/// initialized by a C++ new expression.
clang::ast_matchers::StatementMatcher makeDeclWithNewMatcher();
#endif // CLANG_MODERNIZE_USE_AUTO_MATCHERS_H
|