Inconsistency between `target-pointer-width` and `target-c-int-width`

Hello, I am currently working on a minimalist 32-bit kernel in rust, for this, I use a target specialized (file below), however, I do not understand why target-pointer-width must be a string while target-c-int-width must be an int.

{
"llvm-target": "i686-unknown-none",
"data-layout": "e-m:e-p:32:32-p270:32:32-p271:32:32-p272:64:64-i128:128-f64:32:64-f80:32-n8:16:32-S128",
"arch": "x86",
"target-endian": "little",
"target-pointer-width": "32",
"target-c-int-width": 32,
"os": "none",
"executables": true,
"linker-flavor": "ld.lld",
"linker": "rust-lld",
"panic-strategy": "abort",
"pre-link-args": {
"ld": \[
"-T",
"arch/x86/link.ld",
"-melf_i386"
\]
},
"disable-redzone": true,
"features": "-mmx,-sse,+soft-float",
"rustc-abi": "x86-softfloat"
}

I put here the link to my repo so you can test with cargo build

That seems to have been changed in https://github.com/rust-lang/rust/pull/144218

Make target pointer width in target json an integer #144443 will do that for target-pointer-width as well.

This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.