Douglas Gregor
663b48f13b
Re-uglify #public and #private to #__public_macro and #__private_macro.
...
llvm-svn: 147469
2012-01-03 19:48:16 +00:00
Douglas Gregor
0bf886d41a
Under -fmodules, accept #public <macroname> and #private <macroname>
...
to make a macro public (the default for headers) or private,
respectively.
llvm-svn: 147455
2012-01-03 18:24:14 +00:00
Douglas Gregor
fe76cfd89c
When building a module with an umbrella header, warn about any headers
...
found within that umbrella directory that were not actually included
by the umbrella header. They should either be referenced in the module
map or included by the umbrella header.
llvm-svn: 147207
2011-12-23 00:23:59 +00:00
Douglas Gregor
98a52db80c
Detect when mapping a #include/#import over to a submodule ends up
...
hitting a submodule that was never actually created, e.g., because
that header wasn't parsed. In such cases, complain (because the
module's umbrella headers don't cover everything) and fall back to
including the header.
Later, we'll add a warning at module-build time to catch all such
cases. However, this fallback is important to eliminate assertions in
the ASTWriter when this happens.
llvm-svn: 146933
2011-12-20 00:28:52 +00:00
Douglas Gregor
a95387786d
Don't mark include guard macros as implicitly private. This isn't
...
actually a terribly good heuristic, and the world is too horrible for
it to work.
llvm-svn: 146393
2011-12-12 18:47:39 +00:00
Douglas Gregor
2537a36483
Keep track of import dependencies between submodules within the module
...
that's currently being built. This is important for supporting
transitive dependencies ("export *" in the module map) completely.
llvm-svn: 146156
2011-12-08 17:01:29 +00:00
Douglas Gregor
9458f82df7
Implement inference for the "Private" submodule corresponding to
...
private headers in a framework.
llvm-svn: 146082
2011-12-07 22:05:21 +00:00
Douglas Gregor
e89dbc1d98
When inferring a module map for a framework, infer subframework
...
modules for each of its subframeworks.
llvm-svn: 145957
2011-12-06 19:39:29 +00:00
Douglas Gregor
a89c5ac4a6
Implement inferred submodules support, which (when requested)
...
implicitly generates submodules corresponding to the headers that fall
within a module.
llvm-svn: 145887
2011-12-06 01:10:29 +00:00
Douglas Gregor
ebf0049901
For modules, all macros that aren't include guards are implicitly
...
public. Add a __private_macro__ directive to hide a macro, similar to
the __module_private__ declaration specifier.
llvm-svn: 142188
2011-10-17 15:32:29 +00:00
Douglas Gregor
97eec24b0b
Add an experimental flag -fauto-module-import that automatically turns
...
#include or #import direcctives of framework headers into module
imports of the corresponding framework module.
llvm-svn: 139860
2011-09-15 22:00:41 +00:00
Douglas Gregor
8455e76fa1
Teach LangOptions::resetNonModularOptions to actually do what it says it does
...
llvm-svn: 139791
2011-09-15 14:56:27 +00:00
Douglas Gregor
f1312a828a
When building a module on-demand, clear out the "non-modular" language
...
and preprocessor options (such as macro definitions) first.
llvm-svn: 139638
2011-09-13 20:44:41 +00:00
Douglas Gregor
faeb1d4658
When an import statement fails to find a module in the module cache,
...
but there is a corresponding umbrella header in a framework, build the
module on-the-fly so it can be immediately loaded at the import
statement. This is very much proof-of-concept code, with details to be
fleshed out over time.
llvm-svn: 139558
2011-09-12 23:31:24 +00:00