vsapsai added a comment.
Thanks for the review, Bruno.
Repository:
rC Clang
https://reviews.llvm.org/D49518
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
This revision was automatically updated to reflect the committed changes.
Closed by commit rC339164: [VFS] Emit an error when entry at root level uses a
relative path. (authored by vsapsai, committed by ).
Changed prior to commit:
https://reviews.llvm.org/D49518?vs=157311&id=159567#toc
Reposit
bruno accepted this revision.
bruno added a comment.
This revision is now accepted and ready to land.
LGTM
Comment at: clang/lib/Basic/VirtualFileSystem.cpp:1391
+ error(NameValueNode,
+"entry with relative path at the root level is not discoverable");
+ r
vsapsai updated this revision to Diff 157311.
vsapsai added a comment.
- Make diagnostics more general, use unit tests.
https://reviews.llvm.org/D49518
Files:
clang/lib/Basic/VirtualFileSystem.cpp
clang/unittests/Basic/VirtualFileSystemTest.cpp
Index: clang/unittests/Basic/VirtualFileSyste
vsapsai added a comment.
In https://reviews.llvm.org/D49518#1168038, @bruno wrote:
> Hi Volodymyr, thanks for improving this.
>
> > Need to double check what tests we have when using relative path names at
> > the root level.
>
> Another interesting place to look at is
> `unittests/Basic/Virtua
bruno added a comment.
Hi Volodymyr, thanks for improving this.
> Need to double check what tests we have when using relative path names at the
> root level.
Another interesting place to look at is
`unittests/Basic/VirtualFileSystemTest.cpp`
> I'd like to make the behavior consistent because
vsapsai added a comment.
Need to double check what tests we have when using relative path names at the
root level. I'd like to make the behavior consistent because a file name is a
specific case of relative paths. So far there are no assertions and no errors
but file lookup doesn't seem to be w
vsapsai added inline comments.
Comment at: clang/lib/Basic/VirtualFileSystem.cpp:1416
+if (NameValueNode)
+ error(NameValueNode, "file is not located in any directory");
+return nullptr;
Not happy with the error message but didn't come up
vsapsai created this revision.
vsapsai added reviewers: bruno, benlangmuir.
Herald added a subscriber: dexonsmith.
Orphaned files prevent us from building a file system tree and cause the
assertion
> Assertion failed: (NewParentE && "Parent entry must exist"), function
> uniqueOverlayTree, file