1
0
mirror of https://github.com/cc65/cc65.git synced 2024-12-24 11:31:31 +00:00

Fixed a weird bug. Some special where found to be register variables when they

weren't. Caused by the assignments of the type flags. The flags for the symbol
table entry should get reassigned, because this is not the first time they
caused a problem, but this requires more thought, so I hacked the function
that tests for register vars.


git-svn-id: svn://svn.cc65.org/cc65/trunk@2813 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
cuz 2003-12-21 18:54:39 +00:00
parent 16f312a9ae
commit 72fe2c86a1

View File

@ -189,11 +189,12 @@ INLINE int SymIsRef (const SymEntry* Sym)
#if defined(HAVE_INLINE)
INLINE int SymIsRegVar (const SymEntry* Sym)
/* Return true if the given entry is a register variable */
/* ### HACK! Fix the ugly type flags! */
{
return ((Sym->Flags & SC_REGISTER) == SC_REGISTER);
return ((Sym->Flags & (SC_REGISTER|SC_TYPE)) == SC_REGISTER);
}
#else
# define SymIsRegVar(Sym) (((Sym)->Flags & SC_REGISTER) == SC_REGISTER)
# define SymIsRegVar(Sym) (((Sym)->Flags & (SC_REGISTER|SC_TYPE)) == SC_REGISTER)
#endif
void CvtRegVarToAuto (SymEntry* Sym);