diff options
author | Douglas Gregor <dgregor@apple.com> | 2012-01-27 19:52:33 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2012-01-27 19:52:33 +0000 |
commit | a686e1b05df915030897ec670d9cb15d2a6d0221 (patch) | |
tree | 0c45700a788869289d4dad2a57e18b4e317629bf /clang/lib/Frontend/FrontendAction.cpp | |
parent | 63fe5697f4d9f760fef8ec828d535deec296d119 (diff) | |
download | bcm5719-llvm-a686e1b05df915030897ec670d9cb15d2a6d0221.tar.gz bcm5719-llvm-a686e1b05df915030897ec670d9cb15d2a6d0221.zip |
Introduce module attributes into the module map grammar, along with a
single attribute ("system") that allows us to mark a module as being a
"system" module. Each of the headers that makes up a system module is
considered to be a system header, so that we (for example) suppress
warnings there.
If a module is being inferred for a framework, and that framework
directory is within a system frameworks directory, infer it as a
system framework.
llvm-svn: 149143
Diffstat (limited to 'clang/lib/Frontend/FrontendAction.cpp')
-rw-r--r-- | clang/lib/Frontend/FrontendAction.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/clang/lib/Frontend/FrontendAction.cpp b/clang/lib/Frontend/FrontendAction.cpp index 5a15847aea0..11ac5724795 100644 --- a/clang/lib/Frontend/FrontendAction.cpp +++ b/clang/lib/Frontend/FrontendAction.cpp @@ -320,7 +320,10 @@ void FrontendAction::Execute() { // Initialize the main file entry. This needs to be delayed until after PCH // has loaded. if (!isCurrentFileAST()) { - if (!CI.InitializeSourceManager(getCurrentFile())) + if (!CI.InitializeSourceManager(getCurrentFile(), + getCurrentInput().IsSystem + ? SrcMgr::C_System + : SrcMgr::C_User)) return; } |