pub enum KtDecl {
Class(KtClass),
Fun(KtFun),
FunInterface(KtFunInterface),
Property(KtProperty),
TypeAlias {
vis: KtVis,
name: String,
target: KtType,
},
Raw {
name: String,
code: KtCode,
},
}Expand description
A top-level (or member-level, for Raw) declaration.
Variants§
Class(KtClass)
Fun(KtFun)
FunInterface(KtFunInterface)
Property(KtProperty)
TypeAlias
Raw
Pre-rendered code at declaration position. name is the identity
used for duplicate detection during merge.
Implementations§
Trait Implementations§
Source§impl From<KtFunInterface> for KtDecl
impl From<KtFunInterface> for KtDecl
Source§fn from(i: KtFunInterface) -> Self
fn from(i: KtFunInterface) -> Self
Converts to this type from the input type.
Source§impl From<KtProperty> for KtDecl
impl From<KtProperty> for KtDecl
Source§fn from(p: KtProperty) -> Self
fn from(p: KtProperty) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for KtDecl
impl RefUnwindSafe for KtDecl
impl Send for KtDecl
impl Sync for KtDecl
impl Unpin for KtDecl
impl UnsafeUnpin for KtDecl
impl UnwindSafe for KtDecl
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