Fixed warnings on const comparison.

Warnings on expressions with no effects.
Fixed const ternary.
Fixed ternary with struct/union types as the true/false-branch expressions.
This commit is contained in:
acqn
2020-08-20 07:52:06 +08:00
parent b15ab348ba
commit 3ea3887c77
17 changed files with 399 additions and 132 deletions

View File

@@ -139,6 +139,7 @@ void Assignment (ExprDesc* Expr)
ExprDesc Expr2;
Type* ltype = Expr->Type;
ED_Init (&Expr2);
/* We must have an lvalue for an assignment */
if (ED_IsRVal (Expr)) {