[llvm] Support: unlock Windows API support, switch to Windows 10 RS1+ APIs (PR #102240)
Martin Storsjö via llvm-commits
llvm-commits at lists.llvm.org
Tue Aug 13 13:43:19 PDT 2024
mstorsjo wrote:
Thanks!
I still run into a compiler error due to a technicality:
```
In file included from /home/wbs/code/llvm-project/llvm/lib/Support/Path.cpp:1203:
/home/wbs/code/llvm-project/llvm/lib/Support/Windows/Path.inc:477:7: error: non-constant-expression cannot be narrowed from type 'int' to 'DWORD' (aka 'unsigned long') in initializer list [-Wc++11-narrowing]
477 | { FILE_RENAME_FLAG_POSIX_SEMANTICS | (ReplaceIfExists ? FILE_RENAME_FLAG_REPLACE_IF_EXISTS : 0), FileRenameInfoEx },
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
```
So we need to add a cast to avoid this.
Other than that, this implementation starts looking quite good to me, and it seems to work on Windows 7.
Can you update the PR subject/description to match the current direction of the implementation?
https://github.com/llvm/llvm-project/pull/102240
More information about the llvm-commits
mailing list