[lld] [DRAFT][clang-format][lld] Run clang-format on lld (PR #80461)
Matthias Braun via llvm-commits
llvm-commits at lists.llvm.org
Fri Feb 2 11:15:14 PST 2024
================
@@ -120,17 +120,33 @@ void SectionChunk::applyRelX64(uint8_t *off, uint16_t type, OutputSection *os,
case IMAGE_REL_AMD64_ADDR64:
add64(off, s + imageBase);
break;
- case IMAGE_REL_AMD64_ADDR32NB: add32(off, s); break;
----------------
MatzeB wrote:
This is a situation where I think having it look slightly worse is worth the general consistency autoformatting brings... But for the record you could also go for `// clang-format: off`:
```
// clang-format off
case IMAGE_REL_AMD64_ADDR32NB: add32(off, s); break;
case IMAGE_REL_AMD64_REL32: add32(off, s - p - 4); break;
case IMAGE_REL_AMD64_REL32_1: add32(off, s - p - 5); break;
case IMAGE_REL_AMD64_REL32_2: add32(off, s - p - 6); break;
case IMAGE_REL_AMD64_REL32_3: add32(off, s - p - 7); break;
case IMAGE_REL_AMD64_REL32_4: add32(off, s - p - 8); break;
case IMAGE_REL_AMD64_REL32_5: add32(off, s - p - 9); break;
// clang-format on
```
https://github.com/llvm/llvm-project/pull/80461
More information about the llvm-commits
mailing list