[libcxx-commits] [libcxx] 513463f - [libcxx] Have lexically_normal return the path with preferred separators

Martin Storsjö via libcxx-commits libcxx-commits at lists.llvm.org
Fri Feb 19 11:11:04 PST 2021


Author: Martin Storsjö
Date: 2021-02-19T21:06:54+02:00
New Revision: 513463fd266f059864ce3c0236494cced5de0f56

URL: https://github.com/llvm/llvm-project/commit/513463fd266f059864ce3c0236494cced5de0f56
DIFF: https://github.com/llvm/llvm-project/commit/513463fd266f059864ce3c0236494cced5de0f56.diff

LOG: [libcxx] Have lexically_normal return the path with preferred separators

Differential Revision: https://reviews.llvm.org/D91179

Added: 
    

Modified: 
    libcxx/src/filesystem/operations.cpp

Removed: 
    


################################################################################
diff  --git a/libcxx/src/filesystem/operations.cpp b/libcxx/src/filesystem/operations.cpp
index 458ba1648a183..6f69ca926c523 100644
--- a/libcxx/src/filesystem/operations.cpp
+++ b/libcxx/src/filesystem/operations.cpp
@@ -1717,6 +1717,7 @@ path path::lexically_normal() const {
   if (NeedTrailingSep)
     Result /= PS("");
 
+  Result.make_preferred();
   return Result;
 }
 


        


More information about the libcxx-commits mailing list