diff options
author | Ben Gamari <ben@smart-cactus.org> | 2020-11-23 18:12:15 -0500 |
---|---|---|
committer | Ben Gamari <ben@smart-cactus.org> | 2020-11-27 13:22:47 -0500 |
commit | 0946529c941194902e7944d54cc3571301d6bf5f (patch) | |
tree | ed2683ab90da4d39799b6d70dff023cbe9df9e10 /rts/linker/elf_got.c | |
parent | 32a4d677e5bc3bb006bf180a5d095101485e0f21 (diff) | |
download | haskell-wip/no-assert.tar.gz |
rts/linker: Replace some ASSERTs with CHECKwip/no-assert
In the past some people have confused ASSERT, which is for checking
internal invariants, which CHECK, which should be used when checking
things that might fail due to bad input (and therefore should be enabled
even in the release compiler). Change some of these cases in the linker
to use CHECK.
Diffstat (limited to 'rts/linker/elf_got.c')
-rw-r--r-- | rts/linker/elf_got.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/rts/linker/elf_got.c b/rts/linker/elf_got.c index bdb436ad21..1aca219f9b 100644 --- a/rts/linker/elf_got.c +++ b/rts/linker/elf_got.c @@ -136,10 +136,10 @@ verifyGot(ObjectCode * oc) { for(size_t i=0; i < symTab->n_symbols; i++) { ElfSymbol * symbol = &symTab->symbols[i]; if(symbol->got_addr) { - ASSERT((void*)(*(void**)symbol->got_addr) - == (void*)symbol->addr); + CHECK((void*)(*(void**)symbol->got_addr) + == (void*)symbol->addr); } - ASSERT(0 == ((uintptr_t)symbol->addr & 0xffff000000000000)); + CHECK(0 == ((uintptr_t)symbol->addr & 0xffff000000000000)); } } return EXIT_SUCCESS; |