cabs2cil fails with statements in expression in a question
ID0002508: **This issue was created automatically from Mantis Issue 2508. Further discussion may take place here.** --- | **Id** | **Project** | **Category** | **View** | **Due Date** | **Updated** | | --- | --- | --- | --- | --- | --- | | ID0002508 | Frama-C | Kernel | public | 2020-06-10 | 2020-10-06 | | | | | | | | | --- | --- | --- | --- | --- | --- | | **Reporter** | JoGi | **Assigned To** | AllanBlanchard | **Resolution** | open | | **Priority** | low | **Severity** | minor | **Reproducibility** | always | | **Platform** | Linux | **OS** | Ubuntu | **OS Version** | 18.04 LTS | | **Product Version** | Frama-C 19-Potassium | **Target Version** | - | **Fixed in Version** | - | ### Description : When you have a statement in expression ( https://gcc.gnu.org/onlinedocs/gcc/Statement-Exprs.html ) in a question expression for example « 0 ? ({ printf("1"); }): ({ printf("1"); }); », the type-checker fails. ### Additional Information : If the question expression is not a statement itself (but, for example, a right-value) then the type checking doesn't fail. ### Steps To Reproduce : frama-c ex_stmt_exp.c -kernel-debug 1 Should do the trick. ## Attachments - [ex_stmt_expr.c](/uploads/2d4741c184558b10f5cdc5845bea5ed8/ex_stmt_expr.c)
issue