about summary refs log tree commit diff
path: root/tests/rustdoc/inline_cross/auxiliary/impl-sized.rs
blob: 65f72a3b9ac354994b7fdfeba63e3f561c6f4164 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
use std::fmt::Debug;

pub fn sized(x: impl Sized) -> impl Sized {
    x
}

pub fn sized_outlives<'a>(x: impl Sized + 'a) -> impl Sized + 'a {
    x
}

pub fn maybe_sized(x: &impl ?Sized) -> &impl ?Sized {
    x
}

pub fn debug_maybe_sized(x: &(impl Debug + ?Sized)) -> &(impl Debug + ?Sized) {
    x
}

pub fn maybe_sized_outlives<'t>(x: &(impl ?Sized + 't)) -> &(impl ?Sized + 't) {
    x
}