translate-c: char
always converted to u8
, even on platforms where char
is signed
#9154
Labels
translate-c
C to Zig source translation feature (@cImport)
Milestone
The following C code on
x86_64-macos-gnu
does not call abort; but when run viatranslate-c
it does call abort:In
transType
,.Char_S
is translated asu8
, but it means'char' for targets where it's signed
Treating
.Char_S
as signed will break string literal -> char * implicit casts on those platforms; perhaps the proper thing to do is to special-casechar *
intransType
?The text was updated successfully, but these errors were encountered: