diff options
author | Daniel Chen <cdchen@ca.ibm.com> | 2025-07-08 10:01:43 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-07-08 10:01:43 -0400 |
commit | b84696db745e127cc6fb1d49bbf39f3c0819b6d9 (patch) | |
tree | 616e272556b37f57bf68f84c47016f0bf19d8448 /clang/lib/AST/ByteCode/Compiler.cpp | |
parent | f72e53f35070140cbd6d4acdf7f8bc37f72d0445 (diff) | |
download | llvm-b84696db745e127cc6fb1d49bbf39f3c0819b6d9.zip llvm-b84696db745e127cc6fb1d49bbf39f3c0819b6d9.tar.gz llvm-b84696db745e127cc6fb1d49bbf39f3c0819b6d9.tar.bz2 |
Fix the type of offset that broke 32-bit flang-rt build to use `uint64_t` consistently (#147359)
The recent change of `flang-rt` has code like `std::size_t
offset{offset_};`.
It broke the 32-bit `flang-rt` build because `Component::offset_` is of
type `uint64_t` but `size_t` varies.
Clang complains
```
error: non-constant-expression cannot be narrowed from type 'std::uint64_t' (aka 'unsigned long long') to 'std::size_t' (aka 'unsigned long') in initializer list [-Wc++11-narrowing]
143 | std::size_t offset{offset_};
| ^~~~~~~
```
This patch is to use the consistent `uint64_t` for offset.
Diffstat (limited to 'clang/lib/AST/ByteCode/Compiler.cpp')
0 files changed, 0 insertions, 0 deletions