mirror of
https://github.com/netwide-assembler/nasm
synced 2026-08-26 16:23:04 -04:00
assemble.c: only warn for an absolute address on pass 2
A forward symbol may appear absolute in pass 1, so defer this warning to pass 2. This addresses BR 3392361. Note: this fix is already in the master branch. Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
This commit is contained in:
parent
456b1c46f8
commit
e5f0701d0b
1 changed files with 2 additions and 2 deletions
|
|
@ -1,6 +1,6 @@
|
|||
/* ----------------------------------------------------------------------- *
|
||||
*
|
||||
* Copyright 1996-2016 The NASM Authors - All Rights Reserved
|
||||
* Copyright 1996-2017 The NASM Authors - All Rights Reserved
|
||||
* See the file AUTHORS included with the NASM distribution for
|
||||
* the specific copyright holders.
|
||||
*
|
||||
|
|
@ -2492,7 +2492,7 @@ static enum ea_type process_ea(operand *input, ea *output, int bits,
|
|||
*/
|
||||
if (bits == 64 && ((input->type & IP_REL) == IP_REL) &&
|
||||
input->segment == NO_SEG) {
|
||||
nasm_error(ERR_WARNING | ERR_PASS1, "absolute address can not be RIP-relative");
|
||||
nasm_error(ERR_WARNING | ERR_PASS2, "absolute address can not be RIP-relative");
|
||||
input->type &= ~IP_REL;
|
||||
input->type |= MEMORY;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue