diff options
author | Fangrui Song <i@maskray.me> | 2022-08-06 16:44:14 -0700 |
---|---|---|
committer | Fangrui Song <i@maskray.me> | 2022-08-06 16:44:14 -0700 |
commit | bccdf9197b6d647ccf5bbc86b25e29278aebc4e5 (patch) | |
tree | 2a1a0fe50fdda65513d20a718e049e8e36b7d856 | |
parent | c7ec86b13c461f6a8ce11f8443c1b6242013d26f (diff) |
Revert "[lld-macho] Work around odr-use of const non-inline static data member to fix -O0 build after D128298"
This reverts commit 20b2d3260d4a1878ca2a37cee6ee335a21a12d0f.
The workaround is no longer needed for C++17.
-rw-r--r-- | lld/MachO/SyntheticSections.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/lld/MachO/SyntheticSections.cpp b/lld/MachO/SyntheticSections.cpp index 8e7ca520336c..e8a31f904b44 100644 --- a/lld/MachO/SyntheticSections.cpp +++ b/lld/MachO/SyntheticSections.cpp @@ -1307,8 +1307,7 @@ void CodeSignatureSection::writeHashes(uint8_t *buf) const { uint8_t *hashes = buf + fileOff + allHeadersSize; parallelFor(0, getBlockCount(), [&](size_t i) { sha256(buf + i * blockSize, - std::min(static_cast<size_t>(fileOff - i * blockSize), - static_cast<size_t>(blockSize)), + std::min(static_cast<size_t>(fileOff - i * blockSize), blockSize), hashes + i * hashSize); }); #if defined(__APPLE__) |