pub struct WithBounds<'a>(/* private fields */);Expand description
Display wrapper that shows generic parameters with their bounds
This is used to format generic parameters for display purposes, including both the parameter names and their bounds (if any).
§Example
For a parameter like T: Clone, this will display <T: Clone>.
Trait Implementations§
Source§impl ToTokens for WithBounds<'_>
impl ToTokens for WithBounds<'_>
Source§fn to_tokens(&self, tokens: &mut TokenStream)
fn to_tokens(&self, tokens: &mut TokenStream)
Source§fn to_token_stream(&self) -> TokenStream
fn to_token_stream(&self) -> TokenStream
Source§fn into_token_stream(self) -> TokenStreamwhere
Self: Sized,
fn into_token_stream(self) -> TokenStreamwhere
Self: Sized,
Auto Trait Implementations§
impl<'a> Freeze for WithBounds<'a>
impl<'a> RefUnwindSafe for WithBounds<'a>
impl<'a> !Send for WithBounds<'a>
impl<'a> !Sync for WithBounds<'a>
impl<'a> Unpin for WithBounds<'a>
impl<'a> UnwindSafe for WithBounds<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more