Skip to content

Commit 7d01d51

Browse files
committed
Fix tests
1 parent 9a6b755 commit 7d01d51

File tree

9 files changed

+9
-9
lines changed

9 files changed

+9
-9
lines changed

tests/run/array.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ pub unsafe fn drop_in_place<T: ?Sized>(to_drop: *mut T) {
7979
#[lang = "panic"]
8080
#[track_caller]
8181
#[no_mangle]
82-
pub fn panic(_msg: &str) -> ! {
82+
pub fn panic(_msg: &'static str) -> ! {
8383
unsafe {
8484
libc::puts("Panicking\0" as *const str as *const u8);
8585
intrinsics::abort();

tests/run/assign.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ mod intrinsics {
6464
#[lang = "panic"]
6565
#[track_caller]
6666
#[no_mangle]
67-
pub fn panic(_msg: &str) -> ! {
67+
pub fn panic(_msg: &'static str) -> ! {
6868
unsafe {
6969
libc::puts("Panicking\0" as *const str as *const u8);
7070
libc::fflush(libc::stdout);

tests/run/closure.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ impl Add for isize {
177177
#[lang = "panic"]
178178
#[track_caller]
179179
#[no_mangle]
180-
pub fn panic(_msg: &str) -> ! {
180+
pub fn panic(_msg: &'static str) -> ! {
181181
unsafe {
182182
libc::puts("Panicking\0" as *const str as *const u8);
183183
intrinsics::abort();

tests/run/condition.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ pub unsafe fn drop_in_place<T: ?Sized>(to_drop: *mut T) {
8282
#[lang = "panic"]
8383
#[track_caller]
8484
#[no_mangle]
85-
pub fn panic(_msg: &str) -> ! {
85+
pub fn panic(_msg: &'static str) -> ! {
8686
unsafe {
8787
libc::puts("Panicking\0" as *const str as *const u8);
8888
intrinsics::abort();

tests/run/fun_ptr.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ pub unsafe fn drop_in_place<T: ?Sized>(to_drop: *mut T) {
7676
#[lang = "panic"]
7777
#[track_caller]
7878
#[no_mangle]
79-
pub fn panic(_msg: &str) -> ! {
79+
pub fn panic(_msg: &'static str) -> ! {
8080
unsafe {
8181
libc::puts("Panicking\0" as *const str as *const u8);
8282
intrinsics::abort();

tests/run/int_overflow.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ mod intrinsics {
6262
#[lang = "panic"]
6363
#[track_caller]
6464
#[no_mangle]
65-
pub fn panic(_msg: &str) -> ! {
65+
pub fn panic(_msg: &'static str) -> ! {
6666
unsafe {
6767
// Panicking is expected iff overflow checking is enabled.
6868
#[cfg(debug_assertions)]

tests/run/mut_ref.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ mod intrinsics {
6666
#[lang = "panic"]
6767
#[track_caller]
6868
#[no_mangle]
69-
pub fn panic(_msg: &str) -> ! {
69+
pub fn panic(_msg: &'static str) -> ! {
7070
unsafe {
7171
libc::puts("Panicking\0" as *const str as *const u8);
7272
libc::fflush(libc::stdout);

tests/run/operations.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ mod intrinsics {
7272
#[lang = "panic"]
7373
#[track_caller]
7474
#[no_mangle]
75-
pub fn panic(_msg: &str) -> ! {
75+
pub fn panic(_msg: &'static str) -> ! {
7676
unsafe {
7777
libc::puts("Panicking\0" as *const str as *const u8);
7878
libc::fflush(libc::stdout);

tests/run/ptr_cast.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ pub unsafe fn drop_in_place<T: ?Sized>(to_drop: *mut T) {
7676
#[lang = "panic"]
7777
#[track_caller]
7878
#[no_mangle]
79-
pub fn panic(_msg: &str) -> ! {
79+
pub fn panic(_msg: &'static str) -> ! {
8080
unsafe {
8181
libc::puts("Panicking\0" as *const str as *const u8);
8282
intrinsics::abort();

0 commit comments

Comments
 (0)