1 //===--- ParseAST.h - Define the ParseAST method ----------------*- C++ -*-===//
3 // The LLVM Compiler Infrastructure
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 // This file defines the clang::ParseAST method.
12 //===----------------------------------------------------------------------===//
14 #ifndef LLVM_CLANG_PARSE_PARSEAST_H
15 #define LLVM_CLANG_PARSE_PARSEAST_H
21 class CodeCompleteConsumer;
24 /// \brief Parse the entire file specified, notifying the ASTConsumer as
25 /// the file is parsed.
27 /// This operation inserts the parsed decls into the translation
30 /// \param CompleteTranslationUnit When true, the parsed file is
31 /// considered to be a complete translation unit, and any
32 /// end-of-translation-unit wrapup will be performed.
34 /// \param CompletionConsumer If given, an object to consume code completion
36 void ParseAST(Preprocessor &pp, ASTConsumer *C,
37 ASTContext &Ctx, bool PrintStats = false,
38 bool CompleteTranslationUnit = true,
39 CodeCompleteConsumer *CompletionConsumer = 0);
41 /// \brief Parse the main file known to the preprocessor, producing an
42 /// abstract syntax tree.
43 void ParseAST(Sema &S, bool PrintStats = false);
45 } // end namespace clang