]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - source/Plugins/ExpressionParser/Clang/ASTDumper.h
Vendor import of lldb trunk r290819:
[FreeBSD/FreeBSD.git] / source / Plugins / ExpressionParser / Clang / ASTDumper.h
1 //===-- ASTDumper.h ---------------------------------------------*- C++ -*-===//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9
10 #ifndef liblldb_ASTDumper_h_
11 #define liblldb_ASTDumper_h_
12
13 #include "clang/AST/DeclVisitor.h"
14 #include "clang/AST/TypeVisitor.h"
15
16 #include "lldb/Core/Stream.h"
17 #include "llvm/ADT/DenseSet.h"
18
19 namespace lldb_private {
20
21 class ASTDumper {
22 public:
23   ASTDumper(clang::Decl *decl);
24   ASTDumper(clang::DeclContext *decl_ctx);
25   ASTDumper(const clang::Type *type);
26   ASTDumper(clang::QualType type);
27   ASTDumper(lldb::opaque_compiler_type_t type);
28   ASTDumper(const CompilerType &compiler_type);
29
30   const char *GetCString();
31   void ToSTDERR();
32   void ToLog(Log *log, const char *prefix);
33   void ToStream(lldb::StreamSP &stream);
34
35 private:
36   std::string m_dump;
37 };
38
39 } // namespace lldb_private
40
41 #endif