pub struct TypeParam {
pub attrs: Vec<Attribute>,
pub ident: Ident,
pub colon_token: Option<Colon>,
pub bounds: Punctuated<TypeParamBound, Add>,
pub eq_token: Option<Eq>,
pub default: Option<Type>,
}
Expand description
A generic type parameter: T: Into<String>
.
This type is available only if Syn is built with the "derive"
or
"full"
feature.
Fields
attrs: Vec<Attribute>
ident: Ident
colon_token: Option<Colon>
bounds: Punctuated<TypeParamBound, Add>
eq_token: Option<Eq>
default: Option<Type>
Trait Implementations
sourceimpl From<TypeParam> for GenericParam
impl From<TypeParam> for GenericParam
sourcefn from(e: TypeParam) -> GenericParam
fn from(e: TypeParam) -> GenericParam
Performs the conversion.
Auto Trait Implementations
impl RefUnwindSafe for TypeParam
impl !Send for TypeParam
impl !Sync for TypeParam
impl Unpin for TypeParam
impl UnwindSafe for TypeParam
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more