/// ```
#[rustc_paren_sugar]
#[unstable(feature = "fnbox",
- reason = "will be deprecated if and when Box<FnOnce> becomes usable", issue = "28796")]
+ reason = "will be deprecated if and when `Box<FnOnce>` becomes usable", issue = "28796")]
pub trait FnBox<A> {
type Output;
}
#[unstable(feature = "fnbox",
- reason = "will be deprecated if and when Box<FnOnce> becomes usable", issue = "28796")]
+ reason = "will be deprecated if and when `Box<FnOnce>` becomes usable", issue = "28796")]
impl<A, F> FnBox<A> for F
where F: FnOnce<A>
{
}
#[unstable(feature = "fnbox",
- reason = "will be deprecated if and when Box<FnOnce> becomes usable", issue = "28796")]
+ reason = "will be deprecated if and when `Box<FnOnce>` becomes usable", issue = "28796")]
impl<'a, A, R> FnOnce<A> for Box<FnBox<A, Output = R> + 'a> {
type Output = R;
}
#[unstable(feature = "fnbox",
- reason = "will be deprecated if and when Box<FnOnce> becomes usable", issue = "28796")]
+ reason = "will be deprecated if and when `Box<FnOnce>` becomes usable", issue = "28796")]
impl<'a, A, R> FnOnce<A> for Box<FnBox<A, Output = R> + Send + 'a> {
type Output = R;
if let Some(stab) = item.stability.as_ref() {
let deprecated_reason = if show_reason && !stab.deprecated_reason.is_empty() {
- format!(": {}", stab.deprecated_reason)
+ format!(": {}", Escape(&stab.deprecated_reason))
} else {
String::new()
};
String::new()
};
let unstable_reason = if show_reason && !stab.unstable_reason.is_empty() {
- format!(": {}", stab.unstable_reason)
+ format!(": {}", Escape(&stab.unstable_reason))
} else {
String::new()
};
};
} else if let Some(depr) = item.deprecation.as_ref() {
let note = if show_reason && !depr.note.is_empty() {
- format!(": {}", depr.note)
+ format!(": {}", Escape(&depr.note))
} else {
String::new()
};