Fix 98_al_ax_extend.c compile error

this test is run only on i386 so its failing went unnoticed for
a while, since 1fd3709379.  IS_ASM_SYMs should not be tested
for conflicting types, the C typing overrides.
This commit is contained in:
Michael Matz 2019-04-07 02:44:32 +02:00
parent 9382a3ad58
commit d00f98a7a5

View File

@ -995,7 +995,8 @@ static Sym *external_sym(int v, CType *type, int r, AttributeDef *ad)
{
Sym *s;
s = sym_find(v);
if (!s || (!(s->type.t & VT_EXTERN) && (s->type.t & VT_BTYPE) != VT_FUNC)) {
if (!s || (!IS_ASM_SYM(s) && !(s->type.t & VT_EXTERN)
&& (s->type.t & VT_BTYPE) != VT_FUNC)) {
if (s && !is_compatible_types(&s->type, type))
tcc_error("conflicting types for '%s'", get_tok_str(s->v, NULL));
/* push forward reference */