Commit Graph

9 Commits

Author SHA1 Message Date
Mohammad Ghasembeigi
ee2ceca8d1 Remove unnecessary 'visitDecl' default cases.
The default cases are unnecessary and provide no benefits so they should
just be removed.
2015-12-06 03:08:08 +11:00
Doug Gregor
b8995b0aa3 Transform the Module class into ModuleDecl.
Modules occupy a weird space in the AST now: they can be treated like
types (Swift.Int), which is captured by ModuleType. They can be
treated like values for disambiguation (Swift.print), which is
captured by ModuleExpr. And we jump through hoops in various places to
store "either a module or a decl".

Start cleaning this up by transforming Module into ModuleDecl, a
TypeDecl that's implicitly created to describe a module. Subsequent
changes will start folding away the special cases (ModuleExpr ->
DeclRefExpr, name lookup results stop having a separate Module case,
etc.).

Note that the Module -> ModuleDecl typedef is there to limit the
changes needed. Much of this patch is actually dealing with the fact
that Module used to have Ctx and Name public members that now need to
be accessed via getASTContext() and getName(), respectively.

Swift SVN r28284
2015-05-07 21:10:50 +00:00
Doug Gregor
38cc1fe5c6 Remove LazyResolver arguments from API entry points to the conformance lookup table.
Swift SVN r26838
2015-04-02 00:06:01 +00:00
John McCall
080b7dfabf Remove the default handle-all Decl and DeclAttribute
cases from ASTVisitor and privatize SILGen's statement
emitter.  NFC.

Swift SVN r26402
2015-03-22 03:22:45 +00:00
Doug Gregor
27f58e8f63 Replace a wordlist walk over conformances with NominalTypeDecl::getAllProtocols(). NFC
Swift SVN r26328
2015-03-19 22:10:10 +00:00
Manman Ren
a43db3621f [Driver] add InputFileKind to FrontendOptions.
Separate InputFileKind from SourceFileKind, FrontendOptions will now use
InputFileKind, while Module will use SourceFileKind.

This is in preparation for adding an input file kind for LLVM IR.

rdar://19048891


Swift SVN r25555
2015-02-26 19:13:39 +00:00
Chris Lattner
99aa4352b2 remove upgrading support for the old @class_protocol attribute.
Swift SVN r25526
2015-02-25 02:04:06 +00:00
Dmitri Hrybenko
83032291d2 Module API tool: add some comments
Swift SVN r23972
2014-12-17 02:43:36 +00:00
Dmitri Hrybenko
509bcb3829 Add a skeleton for a module API checker tool
This commit defines a schema and YAML serialization for a significant
portion of our AST.  The API ingestion is a work in progress.

See design discussion in ModuleAPIDiff.cpp.

Swift SVN r23938
2014-12-15 16:58:28 +00:00