Fix crash compiling indexed memcpy size
This commit is contained in:
parent
f619c5e0ab
commit
7aec7f5c50
|
@ -364,7 +364,9 @@ Declaration * GlobalAnalyzer::Analyze(Expression* exp, Declaration* procDec)
|
||||||
if (ldec->mType == DT_VARIABLE || ldec->mType == DT_ARGUMENT)
|
if (ldec->mType == DT_VARIABLE || ldec->mType == DT_ARGUMENT)
|
||||||
ldec = ldec->mBase;
|
ldec = ldec->mBase;
|
||||||
rdec = Analyze(exp->mRight, procDec);
|
rdec = Analyze(exp->mRight, procDec);
|
||||||
return ldec->mBase;
|
if (ldec->mBase)
|
||||||
|
return ldec->mBase;
|
||||||
|
break;
|
||||||
case EX_QUALIFY:
|
case EX_QUALIFY:
|
||||||
Analyze(exp->mLeft, procDec);
|
Analyze(exp->mLeft, procDec);
|
||||||
return exp->mDecValue->mBase;
|
return exp->mDecValue->mBase;
|
||||||
|
|
|
@ -1990,7 +1990,7 @@ InterCodeGenerator::ExValue InterCodeGenerator::TranslateExpression(Declaration*
|
||||||
if (exp->mRight->mType == EX_LIST)
|
if (exp->mRight->mType == EX_LIST)
|
||||||
{
|
{
|
||||||
Expression* tex = exp->mRight->mLeft, * sex = exp->mRight->mRight->mLeft, * nex = exp->mRight->mRight->mRight;
|
Expression* tex = exp->mRight->mLeft, * sex = exp->mRight->mRight->mLeft, * nex = exp->mRight->mRight->mRight;
|
||||||
if (nex->mDecValue->mType == DT_CONST_INTEGER && nex->mDecValue->mInteger < 128)
|
if (nex->mType == EX_CONSTANT && nex->mDecValue->mType == DT_CONST_INTEGER && nex->mDecValue->mInteger < 128)
|
||||||
{
|
{
|
||||||
vl = TranslateExpression(procType, proc, block, tex, breakBlock, continueBlock, inlineMapper);
|
vl = TranslateExpression(procType, proc, block, tex, breakBlock, continueBlock, inlineMapper);
|
||||||
if (vl.mType->mType == DT_TYPE_ARRAY)
|
if (vl.mType->mType == DT_TYPE_ARRAY)
|
||||||
|
|
Loading…
Reference in New Issue