#[non_exhaustive]pub struct ClassConstDecl {
pub name: Ident,
pub modifiers: Modifiers,
pub type_hint: Option<Box<TypeHint>>,
pub value: Expr,
pub attributes: Box<[Attribute]>,
pub doc_comment: Option<Comment>,
}Expand description
A class constant declaration.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.name: IdentConstant name.
modifiers: ModifiersVisibility, static, final, abstract and readonly modifiers.
type_hint: Option<Box<TypeHint>>Declared type.
value: ExprConstant value.
attributes: Box<[Attribute]>Attributes on the constant.
doc_comment: Option<Comment>Preceding doc comment.
Implementations§
Trait Implementations§
Source§impl Clone for ClassConstDecl
impl Clone for ClassConstDecl
Source§impl Debug for ClassConstDecl
impl Debug for ClassConstDecl
Auto Trait Implementations§
impl Freeze for ClassConstDecl
impl RefUnwindSafe for ClassConstDecl
impl Send for ClassConstDecl
impl Sync for ClassConstDecl
impl Unpin for ClassConstDecl
impl UnsafeUnpin for ClassConstDecl
impl UnwindSafe for ClassConstDecl
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