sway-core 0.1.2

Sway core language.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
use crate::parse_tree::Expression;
use crate::Span;
use crate::{type_engine::TypeInfo, Ident};

#[derive(Debug, Clone)]
pub struct VariableDeclaration<'sc> {
    pub name: Ident<'sc>,
    pub type_ascription: TypeInfo,
    pub type_ascription_span: Option<Span<'sc>>,
    pub body: Expression<'sc>, // will be codeblock variant
    pub is_mutable: bool,
}