[PATCH] D30858: Teach llvm's path library to support both windows and posix paths at the same time.

Pavel Labath via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Mar 14 08:56:34 PDT 2017


labath added a comment.

In https://reviews.llvm.org/D30858#700609, @zturner wrote:

> In https://reviews.llvm.org/D30858#700587, @labath wrote:
>
> > All the manipulation functions would remain freestanding as they are now, but they would accept either a `SmallString` (in which case they assume native path syntax) or the `FileSpec` object, where the syntax is stored explicitly. (this would probably require a helper type FileSpecRef, constructible from both, to enable code sharing in the implementation of these functions.)
> >
> > I can live with this implementation, if that's what people consider better, but I think I'd prefer something where you have the path syntax stored explicitly.
>
>
> Well, yea.  I just think that's exactly what LLDB's `FileSpec` class already is (or should be anyway, after removing all the excess stuff, which this patch will enable) ;-)  And I don't think anyone outside of LLDB will ever need it.


Ok, that makes sense. I guess we can pull FileSpec down to llvm if/when another user of the functionality comes up.

> In any case, is anyone opposed to enabling dynamic path syntax support instead of static?

No objection from me.


https://reviews.llvm.org/D30858





More information about the llvm-commits mailing list