From: David Given Date: Wed, 7 Sep 2016 21:09:24 +0000 (+0200) Subject: Ooops --- only emit an error in pass 2 or 3, or else we can't handle forward X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=bdea2b175301d70788bfa4e9b685dc0f23ac6f13;p=ack.git Ooops --- only emit an error in pass 2 or 3, or else we can't handle forward references. --HG-- branch : default-branch --- diff --git a/mach/arm/as/mach5.c b/mach/arm/as/mach5.c index 73f506784..d55beaa6b 100644 --- a/mach/arm/as/mach5.c +++ b/mach/arm/as/mach5.c @@ -210,7 +210,10 @@ void strldr(uint32_t opc, struct expr_t* expr) serror("displacement to near constant is too big"); } - serror("cannot directly address symbols in another section"); + if (pass == PASS_1) + DOTVAL += 4; /* Worst case we can emit */ + else + serror("cannot directly address symbols in another section"); } word_t calcshft(valu_t val, short typ, word_t styp)