https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #17 from YunQiang Su <syq at debian dot org> --- (In reply to Iain Buclaw from comment #16) > (In reply to Iain Buclaw from comment #15) > > Don't think it would fail now the statically allocated size is *at least* > > same as C. But some alias is still not matching up. > core.sys.posix.sys.types is implicitly assuming X86 sizes. (In reply to YunQiang Su from comment #13) > And please have a wait, I need to make sure that this patch can work with > N32. Finally, with help of gdb, This patch can work with both N64 and N32. --- /usr/lib/gcc/mips64el-linux-gnuabi64/11/include/d/core/sys/posix/sys/stat.d 2021-11-18 20:24:46.000000000 +0000 +++ stat.d 2021-12-14 15:22:21.929556158 +0000 @@ -345,7 +345,7 @@ { struct stat_t { - c_ulong st_dev; + ulong st_dev; int[3] st_pad1; static if (!__USE_FILE_OFFSET64) { @@ -353,13 +353,13 @@ } else { - c_ulong st_ino; + ulong st_ino; } mode_t st_mode; nlink_t st_nlink; uid_t st_uid; gid_t st_gid; - c_ulong st_rdev; + ulong st_rdev; static if (!__USE_FILE_OFFSET64) { uint[2] st_pad2; @@ -368,8 +368,8 @@ } else { - c_long[3] st_pad2; - c_long st_size; + uint[3] st_pad2; + long st_size; } static if (__USE_MISC || __USE_XOPEN2K8) { @@ -400,9 +400,9 @@ } else { - c_long st_blocks; + long st_blocks; } - c_long[14] st_pad5; + uint[14] st_pad5; } } else version (PPC)