pub struct Constant {
pub name: Ident,
pub ty: Option<Type>,
pub literal: Literal,
pub id: NodeId,
pub span: Span,
}Expand description
An Ast node representing the declaration of a constant.
Fields§
§name: IdentThe name of the constant stream
ty: Option<Type>The value type of the constant stream
literal: LiteralThe literal defining the constant
id: NodeIdThe id of the node in the Ast
span: SpanThe span in the specification declaring the constant stream
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Constant
impl RefUnwindSafe for Constant
impl Send for Constant
impl Sync for Constant
impl Unpin for Constant
impl UnwindSafe for Constant
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