Details
- Reviewers
• Quuxplusone - Group Reviewers
Restricted Project
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
libcxx/src/filesystem/filesystem_common.h | ||
---|---|---|
115 | How about moving the escaped-double-quotes into this format string? #define PS_FMT "\"%ls\"" #define PS_FMT "\"%s\"" That'll make the call-sites look less wacky. (I admit it doesn't really make any sense that we double-quote these paths in the first place. It's not as if we're going to actually escape the backslashes/quotes in the paths; so the quotation marks are kind of a lie. But I don't feel like unilaterally suggesting their complete removal.) |
libcxx/src/filesystem/filesystem_common.h | ||
---|---|---|
115 | Personally I'd go the opposite way and rather see these macros closer to PRIxYYx macros (cf. https://en.cppreference.com/w/c/types/integer) and so not even include the % sign. This way, they could be used in the future with additional format options, like width, between % and the macro. #define PS_FMT "ls" #define PS_FMT "s" And put % in the format string. WDYT? |
How about moving the escaped-double-quotes into this format string?
That'll make the call-sites look less wacky.
(I admit it doesn't really make any sense that we double-quote these paths in the first place. It's not as if we're going to actually escape the backslashes/quotes in the paths; so the quotation marks are kind of a lie. But I don't feel like unilaterally suggesting their complete removal.)