cannot use if-expression on the left side of an indexexpr #22654
Labels
Status: Confirmed
This bug has been confirmed to be valid by a contributor.
Unit: cgen
Bugs/feature requests, that are related to the default C generating backend.
V doctor:
What did you do?
./v -g -o vdbg cmd/v && ./vdbg test.v
What did you expect to see?
[999, 2, 3]
printed to stdout or a better error messageWhat did you see instead?
Additional information
The following works, meaning that the result of
if true { array_a } else { array_b }
can be assigned to:This issue may be related to #22652.
Note
You can use the 👍 reaction to increase the issue's priority for developers.
Please note that only the 👍 reaction to the issue itself counts as a vote.
Other reactions and those to comments will not be taken into account.
Huly®: V_0.6-21103
The text was updated successfully, but these errors were encountered: