mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
AST: Fewer headers include Expr.h, Module.h, Stmt.h
This commit is contained in:
@@ -19,7 +19,6 @@
|
||||
|
||||
#include "swift/AST/ASTContext.h"
|
||||
#include "swift/AST/Builtins.h"
|
||||
#include "swift/AST/Module.h"
|
||||
#include "swift/AST/SILLayout.h"
|
||||
#include "swift/AST/SILOptions.h"
|
||||
#include "swift/Basic/LangOptions.h"
|
||||
@@ -58,8 +57,10 @@ class Output;
|
||||
namespace swift {
|
||||
class AnyFunctionType;
|
||||
class ASTContext;
|
||||
class FileUnit;
|
||||
class FuncDecl;
|
||||
class KeyPathPattern;
|
||||
class ModuleDecl;
|
||||
class SILUndef;
|
||||
class SourceFile;
|
||||
class SerializedSILLoader;
|
||||
@@ -345,15 +346,12 @@ public:
|
||||
/// later parse SIL bodies directly into, without converting from an AST.
|
||||
static std::unique_ptr<SILModule>
|
||||
createEmptyModule(ModuleDecl *M, SILOptions &Options,
|
||||
bool WholeModule = false) {
|
||||
return std::unique_ptr<SILModule>(
|
||||
new SILModule(M, Options, M, WholeModule));
|
||||
}
|
||||
bool WholeModule = false);
|
||||
|
||||
/// Get the Swift module associated with this SIL module.
|
||||
ModuleDecl *getSwiftModule() const { return TheSwiftModule; }
|
||||
/// Get the AST context used for type uniquing etc. by this SIL module.
|
||||
ASTContext &getASTContext() const { return TheSwiftModule->getASTContext(); }
|
||||
ASTContext &getASTContext() const;
|
||||
SourceManager &getSourceManager() const { return getASTContext().SourceMgr; }
|
||||
|
||||
/// Get the Swift DeclContext associated with this SIL module.
|
||||
|
||||
Reference in New Issue
Block a user