diff options
author | Jonas Devlieghere <jonas@devlieghere.com> | 2018-10-10 13:27:25 +0000 |
---|---|---|
committer | Jonas Devlieghere <jonas@devlieghere.com> | 2018-10-10 13:27:25 +0000 |
commit | fc51490baf1d6ad5796d8cb8bb0792de13ce8fce (patch) | |
tree | bae0cfa9002258ffad07524d654245ed3b918cb1 /clang/lib/Index/SimpleFormatContext.h | |
parent | c616a7236c83994cacdbc13e37269bbc9598093d (diff) | |
download | bcm5719-llvm-fc51490baf1d6ad5796d8cb8bb0792de13ce8fce.tar.gz bcm5719-llvm-fc51490baf1d6ad5796d8cb8bb0792de13ce8fce.zip |
Lift VFS from clang to llvm (NFC)
This patch moves the virtual file system form clang to llvm so it can be
used by more projects.
Concretely the patch:
- Moves VirtualFileSystem.{h|cpp} from clang/Basic to llvm/Support.
- Moves the corresponding unit test from clang to llvm.
- Moves the vfs namespace from clang::vfs to llvm::vfs.
- Formats the lines affected by this change, mostly this is the result of
the added llvm namespace.
RFC on the mailing list:
http://lists.llvm.org/pipermail/llvm-dev/2018-October/126657.html
Differential revision: https://reviews.llvm.org/D52783
llvm-svn: 344140
Diffstat (limited to 'clang/lib/Index/SimpleFormatContext.h')
-rw-r--r-- | clang/lib/Index/SimpleFormatContext.h | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/clang/lib/Index/SimpleFormatContext.h b/clang/lib/Index/SimpleFormatContext.h index 9c6d29bec32..24adcac6020 100644 --- a/clang/lib/Index/SimpleFormatContext.h +++ b/clang/lib/Index/SimpleFormatContext.h @@ -36,12 +36,10 @@ class SimpleFormatContext { public: SimpleFormatContext(LangOptions Options) : DiagOpts(new DiagnosticOptions()), - Diagnostics(new DiagnosticsEngine(new DiagnosticIDs, - DiagOpts.get())), - InMemoryFileSystem(new vfs::InMemoryFileSystem), + Diagnostics(new DiagnosticsEngine(new DiagnosticIDs, DiagOpts.get())), + InMemoryFileSystem(new llvm::vfs::InMemoryFileSystem), Files(FileSystemOptions(), InMemoryFileSystem), - Sources(*Diagnostics, Files), - Rewrite(Sources, Options) { + Sources(*Diagnostics, Files), Rewrite(Sources, Options) { Diagnostics->setClient(new IgnoringDiagConsumer, true); } @@ -63,7 +61,7 @@ public: IntrusiveRefCntPtr<DiagnosticOptions> DiagOpts; IntrusiveRefCntPtr<DiagnosticsEngine> Diagnostics; - IntrusiveRefCntPtr<vfs::InMemoryFileSystem> InMemoryFileSystem; + IntrusiveRefCntPtr<llvm::vfs::InMemoryFileSystem> InMemoryFileSystem; FileManager Files; SourceManager Sources; Rewriter Rewrite; |