[vfs] Don't bail out after a missing -ivfsoverlay file
authorBen Langmuir <blangmuir@apple.com>
Fri, 23 Mar 2018 17:37:27 +0000 (17:37 +0000)
committerBen Langmuir <blangmuir@apple.com>
Fri, 23 Mar 2018 17:37:27 +0000 (17:37 +0000)
commit005c2e57a658bc18529de5027d52619dc4a2a72c
tree486d6d2a2869ab09f3065e360b8c7ba0689c5a7e
parenta237866faff488edf9c822b38e16af3de13c0e90
[vfs] Don't bail out after a missing -ivfsoverlay file

This make -ivfsoverlay behave more like other fatal errors (e.g. missing
-include file) by skipping the missing file instead of bailing out of
the whole compilation. This makes it possible for libclang to still
provide some functionallity as well as to correctly produce the fatal
error diagnostic (previously we lost the diagnostic in libclang since
there was no TU to tie it to).

rdar://33385423

llvm-svn: 328337
clang/include/clang/Frontend/PrecompiledPreamble.h
clang/lib/Frontend/ASTUnit.cpp
clang/lib/Frontend/CompilerInstance.cpp
clang/lib/Frontend/CompilerInvocation.cpp
clang/lib/Frontend/PrecompiledPreamble.cpp
clang/test/Index/missing_vfs.c [new file with mode: 0644]
clang/test/VFS/Inputs/MissingVFS/a.h [new file with mode: 0644]
clang/test/VFS/Inputs/MissingVFS/module.modulemap [new file with mode: 0644]
clang/test/VFS/Inputs/MissingVFS/vfsoverlay.yaml [new file with mode: 0644]
clang/test/VFS/module_missing_vfs.m [new file with mode: 0644]