Skip to content

Commit 468179c

Browse files
committed
Fixup rustc_codegen_gcc test signature
1 parent c0b5cc9 commit 468179c

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

compiler/rustc_codegen_gcc/example/example.rs

+4-3
Original file line numberDiff line numberDiff line change
@@ -153,9 +153,10 @@ fn array_as_slice(arr: &[u8; 3]) -> &[u8] {
153153
arr
154154
}
155155

156-
unsafe fn use_ctlz_nonzero(a: u16) -> u16 {
157-
intrinsics::ctlz_nonzero(a)
158-
}
156+
// FIXME: fix the intrinsic implementation to work with the new ->u32 signature
157+
// unsafe fn use_ctlz_nonzero(a: u16) -> u32 {
158+
// intrinsics::ctlz_nonzero(a)
159+
// }
159160

160161
fn ptr_as_usize(ptr: *const u8) -> usize {
161162
ptr as usize

compiler/rustc_codegen_gcc/example/mini_core.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -593,7 +593,7 @@ pub mod intrinsics {
593593
pub fn min_align_of_val<T: ?Sized>(val: *const T) -> usize;
594594
pub fn copy<T>(src: *const T, dst: *mut T, count: usize);
595595
pub fn transmute<T, U>(e: T) -> U;
596-
pub fn ctlz_nonzero<T>(x: T) -> T;
596+
pub fn ctlz_nonzero<T>(x: T) -> u32;
597597
#[rustc_safe_intrinsic]
598598
pub fn needs_drop<T: ?Sized>() -> bool;
599599
#[rustc_safe_intrinsic]

0 commit comments

Comments
 (0)