commit d1aaddfaf1df5dd19a2781095fc4911b4707f51f
parent 8f3c59e735bdfdd60de0032dbbb938256ca90549
Author: Bor Grošelj Simić <bor.groseljsimic@telemach.net>
Date: Thu, 4 Mar 2021 23:01:04 +0100
eval.c: evaluate compile-time logical AND with &&
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/eval.c b/src/eval.c
@@ -193,7 +193,7 @@ eval_binarithm(struct context *ctx, struct expression *in, struct expression *ou
case BIN_LAND:
assert(type_dealias(lvalue.result)->storage == STORAGE_BOOL
&& type_dealias(rvalue.result)->storage == STORAGE_BOOL);
- bval = blval || brval;
+ bval = blval && brval;
break;
case BIN_LEQUAL:
if (type_is_signed(lvalue.result)) {