[COFF] Remove a truncation assertion from setRVA

LLD already produces a nice error message when sections exceed 4GB, and
this setRVA assertion causes LLD to crash instead of diagnosing the
error properly.

No test because we don't want slow tests that create 4GB files.
This commit is contained in:
Reid Kleckner 2021-05-13 19:32:49 -07:00
parent a088bed4e3
commit ee23f8b36f
1 changed files with 1 additions and 1 deletions

View File

@ -86,8 +86,8 @@ public:
// can be stored with 32 bits.
uint32_t getRVA() const { return rva; }
void setRVA(uint64_t v) {
// This may truncate. The writer checks for overflow later.
rva = (uint32_t)v;
assert(rva == v && "RVA truncated");
}
// Returns readable/writable/executable bits.