[qfcc] Unalias type before checking for pointer/reference

Before adding references, looking at just type.type was ok whether or
not the type was an alias, but checking the deref flag needs the type to
be basic and not alias.
This commit is contained in:
Bill Currie 2024-10-09 11:31:00 +09:00
parent a61e20ab20
commit 421796b9ea

View file

@ -1293,12 +1293,14 @@ int is_##t (const type_t *type) \
int
is_pointer (const type_t *type)
{
type = unalias_type (type);
return is_ptr (type) && !type->fldptr.deref;
}
int
is_reference (const type_t *type)
{
type = unalias_type (type);
return is_ptr (type) && type->fldptr.deref;
}