From: cuz Date: Sat, 6 Dec 2003 14:44:16 +0000 (+0000) Subject: Fixed a bug X-Git-Tag: V2.12.0~1083 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=87857eced33bfa62c787a7be7befdcf496893d93;p=cc65 Fixed a bug git-svn-id: svn://svn.cc65.org/cc65/trunk@2720 b7a2c559-68d2-44c3-8de9-860c34a00d81 --- diff --git a/src/ca65/expr.c b/src/ca65/expr.c index ca6f24916..1d066784f 100644 --- a/src/ca65/expr.c +++ b/src/ca65/expr.c @@ -404,12 +404,16 @@ static ExprNode* FuncSizeOf (void) /* Cheap local symbol */ Sym = SymFindLocal (SymLast, SVal, SYM_FIND_EXISTING); if (Sym == 0) { - Error ("Unknown symbol or scope: `%s%s'", - SB_GetConstBuf (&ScopeName), Name); + Error ("Unknown symbol or scope: `%s'", SVal); } else { SizeSym = GetSizeOfSymbol (Sym); } + /* Remember and skip SVal, terminate ScopeName so it is empty */ + strcpy (Name, SVal); + NextTok (); + SB_Terminate (&ScopeName); + } else { /* Parse the scope and the name */