Fix const eval of sin/cos
This commit is contained in:
parent
da5326cc5f
commit
63725f3511
|
@ -867,9 +867,9 @@ Expression* Expression::ConstantFold(Errors * errors, LinkerSection * dataSectio
|
||||||
Declaration* decf = mLeft->mDecValue, * decp = mRight->mDecValue;
|
Declaration* decf = mLeft->mDecValue, * decp = mRight->mDecValue;
|
||||||
const Ident* iname = decf->mQualIdent;
|
const Ident* iname = decf->mQualIdent;
|
||||||
|
|
||||||
if (decp->mType == DT_TYPE_FLOAT || decp->mType == DT_TYPE_INTEGER)
|
if (decp->mType == DT_CONST_FLOAT || decp->mType == DT_CONST_INTEGER)
|
||||||
{
|
{
|
||||||
double d = decp->mType == DT_TYPE_FLOAT ? decp->mNumber : decp->mInteger;
|
double d = decp->mType == DT_CONST_FLOAT ? decp->mNumber : decp->mInteger;
|
||||||
|
|
||||||
bool check = false;
|
bool check = false;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue