mirror of
https://github.com/cc65/cc65.git
synced 2024-11-18 00:07:21 +00:00
Indexing a string by an expression which was not a simple variable didn't
work: "abcd"[atoi("2")]; git-svn-id: svn://svn.cc65.org/cc65/trunk@3880 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
parent
9127774a4d
commit
5cd0b86a1a
@ -80,7 +80,9 @@ static unsigned GlobalModeFlags (const ExprDesc* Expr)
|
|||||||
/* Return the addressing mode flags for the given expression */
|
/* Return the addressing mode flags for the given expression */
|
||||||
{
|
{
|
||||||
switch (ED_GetLoc (Expr)) {
|
switch (ED_GetLoc (Expr)) {
|
||||||
|
case E_LOC_ABS: return CF_ABSOLUTE;
|
||||||
case E_LOC_GLOBAL: return CF_EXTERNAL;
|
case E_LOC_GLOBAL: return CF_EXTERNAL;
|
||||||
|
case E_LOC_LITERAL: /* Same as static */
|
||||||
case E_LOC_STATIC: return CF_STATIC;
|
case E_LOC_STATIC: return CF_STATIC;
|
||||||
case E_LOC_REGISTER: return CF_REGVAR;
|
case E_LOC_REGISTER: return CF_REGVAR;
|
||||||
default:
|
default:
|
||||||
|
Loading…
Reference in New Issue
Block a user