Skip to content

Commit

Permalink
Remove windows-specific copy of test
Browse files Browse the repository at this point in the history
  • Loading branch information
oli-obk committed Jun 17, 2024
1 parent 7a52206 commit 9802e15
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 83 deletions.

This file was deleted.

58 changes: 0 additions & 58 deletions tests/ui/coercion/coerce-issue-49593-box-never-windows.rs

This file was deleted.

11 changes: 5 additions & 6 deletions tests/ui/coercion/coerce-issue-49593-box-never.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
//@ revisions: nofallback fallback
//@ ignore-windows - the number of `Error` impls is platform-dependent
//@check-fail

#![feature(never_type)]
Expand All @@ -21,13 +20,14 @@ fn foo(x: !) -> Box<dyn Error> {
}

fn foo_raw_ptr(x: !) -> *mut dyn Error {
/* *mut $0 is coerced to *mut Error here */ raw_ptr_box::<_ /* ! */>(x)
/* *mut $0 is coerced to *mut Error here */
raw_ptr_box::<_ /* ! */>(x)
//[nofallback]~^ ERROR trait bound `(): std::error::Error` is not satisfied
}

fn no_coercion(d: *mut dyn Error) -> *mut dyn Error {
/* an unsize coercion won't compile here, and it is indeed not used
because there is nothing requiring the _ to be Sized */
because there is nothing requiring the _ to be Sized */
d as *mut _
}

Expand All @@ -50,10 +50,9 @@ fn foo_no_never() {
first_iter = true;
}

let mut y : Option<S> = None;
let mut y: Option<S> = None;
// assert types are equal
mem::swap(&mut x, &mut y);
}

fn main() {
}
fn main() {}

0 comments on commit 9802e15

Please sign in to comment.