Commit Graph

6 Commits

Author SHA1 Message Date
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
Argyrios Kyrtzidis
a586753f0f [IDE] Implement generating the Swift interface for an C/ObjC header
This translates clang arguments to swift ones, uses the bridging header
functionality to parse the provided file, and re-uses part of the module interface
printing implementation to print an interface for the header.

Part of rdar://19939192

Swift SVN r28062
2015-05-02 01:17:45 +00:00
Doug Gregor
1a6d27079d Module interface printing: add an option to skip the Swift overlay.
This is a debugging aid, not a general feature, hence the lack of
testing or actual, correct semantics.

Swift SVN r15886
2014-04-03 18:07:59 +00:00
Doug Gregor
8b684f3f7c Module interface printing: bring back printing of submodules.
Brings back the behavior removed in r15800 under a pair of flags
(-module-print-submodules and -module-print-hidden) that control
whether to print submodules, possibly including submodules that aren't
explicitly visible.

Swift SVN r15872
2014-04-03 16:10:11 +00:00
Dmitri Hrybenko
efb2a60ee7 Module interface printing: add a libIDE API to print a Clang submodule
Swift SVN r15730
2014-04-01 14:51:58 +00:00
Dmitri Hrybenko
7e294eea4d Module interface printing: print imported Clang declarations in header source
order

rdar://problem/16408837


Swift SVN r15505
2014-03-26 11:36:25 +00:00