diff --git a/lld/ELF/InputSection.h b/lld/ELF/InputSection.h index 912b969fe3c41..e9b1ffadf44f5 100644 --- a/lld/ELF/InputSection.h +++ b/lld/ELF/InputSection.h @@ -149,6 +149,8 @@ class InputSectionBase : public SectionBase { bytesDropped -= num; } + mutable ArrayRef rawData; + void trim() { if (bytesDropped) { rawData = rawData.drop_back(bytesDropped); @@ -220,8 +222,6 @@ class InputSectionBase : public SectionBase { return llvm::makeArrayRef((const T *)rawData.data(), s / sizeof(T)); } - mutable ArrayRef rawData; - protected: template void parseCompressedHeader();