Fix internal const cast
This commit is contained in:
parent
f99abb32e2
commit
f43f471124
|
@ -2428,7 +2428,7 @@ Declaration* Declaration::ToMutableType(void)
|
|||
ndec->mBase = mBase;
|
||||
ndec->mBits = mBits;
|
||||
ndec->mShift = mShift;
|
||||
ndec->mFlags = mFlags | DTF_CONST;
|
||||
ndec->mFlags = mFlags & ~DTF_CONST;
|
||||
ndec->mScope = mScope;
|
||||
ndec->mParams = mParams;
|
||||
ndec->mIdent = mIdent;
|
||||
|
|
|
@ -53089,7 +53089,7 @@ bool NativeCodeBasicBlock::PeepHoleOptimizerExits(int pass)
|
|||
mIns[sz - 3] = mIns[sz - 1];
|
||||
mIns[sz - 1].mType = ASMIT_NOP; mIns[sz - 1].mMode = ASMIM_IMPLIED;
|
||||
|
||||
mIns[sz - 2].mLive |= LIVE_CPU_REG_Z;
|
||||
mIns[sz - 2].mLive |= LIVE_CPU_REG_Z | LIVE_CPU_REG_X;
|
||||
if (mIns[sz - 2].ReferencesYReg()) mIns[sz - 3].mLive |= LIVE_CPU_REG_Y;
|
||||
if (mBranch == ASMIT_BCC)
|
||||
mBranch = ASMIT_BPL;
|
||||
|
|
|
@ -9010,6 +9010,10 @@ Expression* Parser::ParseAddExpression(bool lhs)
|
|||
}
|
||||
else if (nexp->mLeft->mDecType->mType == DT_TYPE_FLOAT || nexp->mRight->mDecType->mType == DT_TYPE_FLOAT)
|
||||
nexp->mDecType = TheFloatTypeDeclaration;
|
||||
else if (nexp->mToken == TK_SUB &&
|
||||
(nexp->mLeft->mDecType->mType == DT_TYPE_POINTER || nexp->mLeft->mDecType->mType == DT_TYPE_ARRAY) &&
|
||||
(nexp->mRight->mDecType->mType == DT_TYPE_POINTER || nexp->mRight->mDecType->mType == DT_TYPE_ARRAY))
|
||||
nexp->mDecType = TheSignedIntTypeDeclaration;
|
||||
else
|
||||
nexp->mDecType = exp->mDecType;
|
||||
|
||||
|
@ -10710,7 +10714,7 @@ Expression* Parser::ParseStatement(void)
|
|||
if (mFunctionType->mBase->mType == DT_TYPE_AUTO || mFunctionType->mBase->IsReference() && mFunctionType->mBase->mBase->mType == DT_TYPE_AUTO)
|
||||
{
|
||||
mFunctionType->mBase = mFunctionType->mBase->DeduceAuto(exp->mLeft->mDecType);
|
||||
;
|
||||
|
||||
if (mFunctionType->mBase->mType == DT_TYPE_STRUCT)
|
||||
{
|
||||
// Make room for value struct return
|
||||
|
|
Loading…
Reference in New Issue