llvm-project
70321b9c - [Support] Support runtime override for LLVM_WINDOWS_PREFER_FORWARD_SLASH (#199210)

Commit
1 day ago
[Support] Support runtime override for LLVM_WINDOWS_PREFER_FORWARD_SLASH (#199210) Allow overriding the compile-time LLVM_WINDOWS_PREFER_FORWARD_SLASH setting at runtime using an environment variable of the same name. This enables testing both path separator behaviors (forward slash vs. backslash on Windows) using a single build, which is useful for CI/Buildbots. The environment variable is checked once and cached in a static variable for performance. Also updated relevant tests in SupportTests (Path.cpp and CommandLineTest.cpp) to dynamically detect the preferred separator style at runtime instead of relying on the compile-time macro, making them compatible with the override.
Author
Parents
Loading