Skip to content

Commit cfd932d

Browse files
committed
Auto merge of #3064 - colincross:patch-2, r=JohnTitor
Fix compile error for riscv64-linux-android Fixes: error[E0369]: cannot subtract `char` from `char` --> prebuilts/rust/linux-x86/1.64.0/src/stdlibs/vendor/libc/src/unix/linux_like/android/b64/riscv64/mod.rs:63:53 | 63 | pub const COMPAT_HWCAP_ISA_I: ::c_ulong = 1 << ('I' - 'A'); | --- ^ --- char | | | char
2 parents 053843a + a7f9d0a commit cfd932d

File tree

1 file changed

+6
-6
lines changed
  • src/unix/linux_like/android/b64/riscv64

1 file changed

+6
-6
lines changed

src/unix/linux_like/android/b64/riscv64/mod.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -60,12 +60,12 @@ pub const SIGSTKSZ: ::size_t = 8192;
6060
pub const MINSIGSTKSZ: ::size_t = 2048;
6161

6262
// From NDK's asm/hwcap.h
63-
pub const COMPAT_HWCAP_ISA_I: ::c_ulong = 1 << ('I' - 'A');
64-
pub const COMPAT_HWCAP_ISA_M: ::c_ulong = 1 << ('M' - 'A');
65-
pub const COMPAT_HWCAP_ISA_A: ::c_ulong = 1 << ('A' - 'A');
66-
pub const COMPAT_HWCAP_ISA_F: ::c_ulong = 1 << ('F' - 'A');
67-
pub const COMPAT_HWCAP_ISA_D: ::c_ulong = 1 << ('D' - 'A');
68-
pub const COMPAT_HWCAP_ISA_C: ::c_ulong = 1 << ('C' - 'A');
63+
pub const COMPAT_HWCAP_ISA_I: ::c_ulong = 1 << (b'I' - b'A');
64+
pub const COMPAT_HWCAP_ISA_M: ::c_ulong = 1 << (b'M' - b'A');
65+
pub const COMPAT_HWCAP_ISA_A: ::c_ulong = 1 << (b'A' - b'A');
66+
pub const COMPAT_HWCAP_ISA_F: ::c_ulong = 1 << (b'F' - b'A');
67+
pub const COMPAT_HWCAP_ISA_D: ::c_ulong = 1 << (b'D' - b'A');
68+
pub const COMPAT_HWCAP_ISA_C: ::c_ulong = 1 << (b'C' - b'A');
6969

7070
pub const SYS_io_setup: ::c_long = 0;
7171
pub const SYS_io_destroy: ::c_long = 1;

0 commit comments

Comments
 (0)