Zig Version
0.11.0-dev.1580+a5b34a61a
Steps to Reproduce and Observed Behavior
const std = @import("std");
pub fn main() void {
const Cint = @Type(@typeInfo(c_int));
std.log.info("{} {} {}", .{ c_int == i32, Cint == c_int, Cint == i32 });
}
on linux amd64:
Expected Behavior
Not sure if this is intended. It is quite confusing.
- If this is intended, it should be documented.
- Or
c_int and i32 has different internal type id, but c_int == i32 holds on amd64 targets and c_int == i16 holds on some embedded targets.
Zig Version
0.11.0-dev.1580+a5b34a61a
Steps to Reproduce and Observed Behavior
on linux amd64:
Expected Behavior
Not sure if this is intended. It is quite confusing.
c_intandi32has different internal type id, butc_int == i32holds on amd64 targets andc_int == i16holds on some embedded targets.