diff --git a/include/asm/output.h b/include/asm/output.h index 46fffb3b..f888f6bd 100644 --- a/include/asm/output.h +++ b/include/asm/output.h @@ -40,7 +40,6 @@ void out_AbsByteGroup(char *s, int32_t length); void out_RelByte(struct Expression *expr); void out_RelWord(struct Expression *expr); void out_PCRelByte(struct Expression *expr); -void out_CheckErrors(void); void out_WriteObject(void); void out_Skip(int32_t skip); void out_BinaryFile(char *s); diff --git a/src/asm/main.c b/src/asm/main.c index 669e389a..f74b8277 100644 --- a/src/asm/main.c +++ b/src/asm/main.c @@ -471,7 +471,6 @@ int main(int argc, char *argv[]) (int)(60 / timespent * nTotalLines)); } - out_CheckErrors(); /* If no path specified, don't write file */ if (tzObjectname != NULL) out_WriteObject(); diff --git a/src/asm/output.c b/src/asm/output.c index 0c34e3e8..1f8c4c96 100644 --- a/src/asm/output.c +++ b/src/asm/output.c @@ -526,34 +526,6 @@ static void checksectionoverflow(uint32_t delta_size) } } -/* - * Check for errors that could happen while writing an object file - * This is important as out_WriteObject is skipped entirely when `-o` is omitted - * Therefore, errors such as memory allocations still should be handled in - * out_WriteObject and not here - */ -void out_CheckErrors(void) -{ - /* Local symbols cannot be imported from elsewhere */ - struct PatchSymbol *pSym = pPatchSymbols; - - while (pSym) { - struct sSymbol const *pSymbol = pSym->pSymbol; - - if (!(pSymbol->nType & SYMF_DEFINED) - && pSymbol->nType & SYMF_LOCAL) { - char const *name = pSymbol->tzName; - char const *localPtr = strchr(name, '.'); - - if (localPtr) - name = localPtr; - errx(1, "%s(%u) : '%s' not defined", - pSymbol->tzFileName, pSymbol->nFileLine, name); - } - pSym = pSym->pNext; - } -} - /* * Write an objectfile */ diff --git a/test/asm/undefined-dot.err b/test/asm/undefined-dot.err index 511659b7..e69de29b 100644 --- a/test/asm/undefined-dot.err +++ b/test/asm/undefined-dot.err @@ -1 +0,0 @@ -error: undefined-dot.asm(3) : '.' not defined