nushell/crates/nu-protocol/src/variable.rs

19 lines
342 B
Rust
Raw Normal View History

2022-03-09 10:42:19 +01:00
use crate::{Span, Type};
#[derive(Clone, Debug)]
pub struct Variable {
pub declaration_span: Span,
pub ty: Type,
pub mutable: bool,
2022-03-09 10:42:19 +01:00
}
impl Variable {
pub fn new(declaration_span: Span, ty: Type, mutable: bool) -> Variable {
2022-03-09 10:42:19 +01:00
Self {
declaration_span,
ty,
mutable,
2022-03-09 10:42:19 +01:00
}
}
}