This revision was automatically updated to reflect the committed changes.
Closed by commit rC340937: [Tooling] Do not restore working dir in ClangTool
(authored by ibiryukov, committed by ).
Changed prior to commit:
https://reviews.llvm.org/D51407?vs=163122&id=163127#toc
Repository:
rC Clang
This revision was automatically updated to reflect the committed changes.
Closed by commit rL340937: [Tooling] Do not restore working dir in ClangTool
(authored by ibiryukov, committed by ).
Herald added a subscriber: llvm-commits.
Repository:
rL LLVM
https://reviews.llvm.org/D51407
Files:
ilya-biryukov updated this revision to Diff 163122.
ilya-biryukov added a comment.
- Expose getAbsolutePath in the public API
Repository:
rC Clang
https://reviews.llvm.org/D51407
Files:
include/clang/Tooling/Tooling.h
lib/Tooling/Tooling.cpp
Index: lib/Tooling/Tooling.cpp
==
ioeric accepted this revision.
ioeric added a comment.
This revision is now accepted and ready to land.
lg
Comment at: lib/Tooling/Tooling.cpp:202
-std::string getAbsolutePath(StringRef File) {
+static llvm::Expected getAbsolutePath(vfs::FileSystem &FS,
+
ilya-biryukov added inline comments.
Comment at: lib/Tooling/Tooling.cpp:419
- } else {
-llvm::report_fatal_error("Cannot detect current path: " +
- Twine(CWD.getError().message()));
ioeric wrote:
> ilya-biryukov wrote:
> > ioeric
ilya-biryukov updated this revision to Diff 163071.
ilya-biryukov added a comment.
- Use vfs for file accesses
- Report errors when getAbsolutePath fails, skip those files
Repository:
rC Clang
https://reviews.llvm.org/D51407
Files:
lib/Tooling/Tooling.cpp
Index: lib/Tooling/Tooling.cpp
=
ioeric added inline comments.
Comment at: lib/Tooling/Tooling.cpp:419
- } else {
-llvm::report_fatal_error("Cannot detect current path: " +
- Twine(CWD.getError().message()));
ilya-biryukov wrote:
> ioeric wrote:
> > Should we sti
ilya-biryukov added inline comments.
Comment at: lib/Tooling/Tooling.cpp:419
- } else {
-llvm::report_fatal_error("Cannot detect current path: " +
- Twine(CWD.getError().message()));
ioeric wrote:
> Should we still check if `CWD`
ioeric added inline comments.
Comment at: lib/Tooling/Tooling.cpp:419
- } else {
-llvm::report_fatal_error("Cannot detect current path: " +
- Twine(CWD.getError().message()));
Should we still check if `CWD` is correctly set?
Rep
ilya-biryukov created this revision.
ilya-biryukov added reviewers: ioeric, sammccall.
Resolve all relative paths before running the tool instead.
This fixes the usage of ClangTool in AllTUsExecutor. The executor will
try running multiple ClangTool instances in parallel with compile
commands that
10 matches
Mail list logo