mirror of
https://github.com/erg-lang/erg.git
synced 2025-10-02 21:44:34 +00:00
WIP: Impl DataPack type checking
This commit is contained in:
parent
e7898c094e
commit
263c43d74b
7 changed files with 119 additions and 58 deletions
|
@ -897,6 +897,7 @@ impl Call {
|
|||
#[derive(Clone, Debug, PartialEq, Eq, Hash)]
|
||||
pub struct DataPack {
|
||||
pub class: Box<Expr>,
|
||||
pub connector: Token,
|
||||
pub args: Record,
|
||||
}
|
||||
|
||||
|
@ -915,9 +916,10 @@ impl Locational for DataPack {
|
|||
}
|
||||
|
||||
impl DataPack {
|
||||
pub fn new(class: Expr, args: Record) -> Self {
|
||||
pub fn new(class: Expr, connector: Token, args: Record) -> Self {
|
||||
Self {
|
||||
class: Box::new(class),
|
||||
connector,
|
||||
args,
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue