Returning fixed size arrays is still making C errors, even with the size being a normal int #22058
Labels
Bug
This tag is applied to issues which reports bugs.
Comptime
Features processed during compile time, like $if, $for, $env etc
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.
Unit: Compiler
Bugs/feature requests, that are related to the V compiler in general.
V doctor:
What did you do?
./v -g -o vdbg cmd/v && ./vdbg src/board.v
What did you expect to see?
Still a function that returns a fixed size u8 array with 49 zeroes in it. We've established that nsq being a u16 breaks everything, but somehow even without that there is a bug. At least I can initialize my array by making it mutable and passing it in as an argument.
What did you see instead?
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.
The text was updated successfully, but these errors were encountered: