mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-04 18:40:57 +03:00
fix test case
This commit is contained in:
@@ -36,7 +36,7 @@ fn main() {
|
||||
|
||||
assert_eq!(
|
||||
panic::catch_unwind(|| {
|
||||
mem::MaybeUninit::<!>::uninitialized().into_inner()
|
||||
mem::MaybeUninit::<!>::uninitialized().into_initialized()
|
||||
}).err().and_then(|a| a.downcast_ref::<String>().map(|s| {
|
||||
s == "Attempted to instantiate uninhabited type !"
|
||||
})),
|
||||
@@ -63,7 +63,7 @@ fn main() {
|
||||
|
||||
assert_eq!(
|
||||
panic::catch_unwind(|| {
|
||||
mem::MaybeUninit::<Foo>::uninitialized().into_inner()
|
||||
mem::MaybeUninit::<Foo>::uninitialized().into_initialized()
|
||||
}).err().and_then(|a| a.downcast_ref::<String>().map(|s| {
|
||||
s == "Attempted to instantiate uninhabited type Foo"
|
||||
})),
|
||||
@@ -90,7 +90,7 @@ fn main() {
|
||||
|
||||
assert_eq!(
|
||||
panic::catch_unwind(|| {
|
||||
mem::MaybeUninit::<Bar>::uninitialized().into_inner()
|
||||
mem::MaybeUninit::<Bar>::uninitialized().into_initialized()
|
||||
}).err().and_then(|a| a.downcast_ref::<String>().map(|s| {
|
||||
s == "Attempted to instantiate uninhabited type Bar"
|
||||
})),
|
||||
|
||||
Reference in New Issue
Block a user