This is an archive of the discontinued LLVM Phabricator instance.

FileSpec: Remove PathSyntax enum and use llvm version instead
ClosedPublic

Authored by labath on May 11 2018, 6:13 AM.

Details

Summary

The llvm version of the enum has the same enumerators, with stlightly
different names, so this is mostly just a search&replace exercise. One
concrete benefit of this is that we can remove the function for
converting between the two enums.

To avoid typing llvm::sys::path::Style::windows everywhere I import the
enum into the FileSpec class, so it can be referenced as
FileSpec::Style::windows.

Diff Detail

Repository
rL LLVM

Event Timeline

labath created this revision.May 11 2018, 6:13 AM
clayborg accepted this revision.May 11 2018, 9:18 AM

Fine to use llvm's enum as long as we don't export the style through the SB API

This revision is now accepted and ready to land.May 11 2018, 9:18 AM

We don't export the style right now. At some point we may need to teach SBFileSpec about path styles, but at that point I'd just do the translation at the SB level, and let everyone else use the llvm enum.

This revision was automatically updated to reflect the committed changes.