Skip to content

Commit

Permalink
Change undefined-behavior doctests from ignore to no_run.
Browse files Browse the repository at this point in the history
  • Loading branch information
zachs18 committed Nov 18, 2022
1 parent f542b06 commit 734f724
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions library/alloc/src/rc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1111,7 +1111,7 @@ impl<T: ?Sized> Rc<T> {
/// assert_eq!(*x, "foo");
/// ```
/// Other `Rc` pointers to the same allocation must be to the same type.
/// ```ignore
/// ```no_run
/// #![feature(get_mut_unchecked)]
///
/// use std::rc::Rc;
Expand All @@ -1125,7 +1125,7 @@ impl<T: ?Sized> Rc<T> {
/// println!("{}", &*x); // Invalid UTF-8 in a str
/// ```
/// Other `Rc` pointers to the same allocation must be to the exact same type, including lifetimes.
/// ```ignore
/// ```no_run
/// #![feature(get_mut_unchecked)]
///
/// use std::rc::Rc;
Expand Down
4 changes: 2 additions & 2 deletions library/alloc/src/sync.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1650,7 +1650,7 @@ impl<T: ?Sized> Arc<T> {
/// assert_eq!(*x, "foo");
/// ```
/// Other `Arc` pointers to the same allocation must be to the same type.
/// ```ignore
/// ```no_run
/// #![feature(get_mut_unchecked)]
///
/// use std::sync::Arc;
Expand All @@ -1664,7 +1664,7 @@ impl<T: ?Sized> Arc<T> {
/// println!("{}", &*x); // Invalid UTF-8 in a str
/// ```
/// Other `Arc` pointers to the same allocation must be to the exact same type, including lifetimes.
/// ```ignore
/// ```no_run
/// #![feature(get_mut_unchecked)]
///
/// use std::sync::Arc;
Expand Down

0 comments on commit 734f724

Please sign in to comment.