mirror of
https://github.com/HigherOrderCO/Kind1.git
synced 2024-09-11 08:45:32 +03:00
chore: fix newlines
This commit is contained in:
parent
91ed7314a6
commit
2a7df0a3c7
@ -290,17 +290,13 @@ impl<'a> Visitor for Subst<'a> {
|
|||||||
}
|
}
|
||||||
ExprKind::SeqRecord(sec) => {
|
ExprKind::SeqRecord(sec) => {
|
||||||
use kind_tree::concrete::SeqOperation::*;
|
use kind_tree::concrete::SeqOperation::*;
|
||||||
|
|
||||||
self.visit_expr(&mut sec.expr);
|
self.visit_expr(&mut sec.expr);
|
||||||
|
|
||||||
self.visit_expr(&mut sec.typ);
|
self.visit_expr(&mut sec.typ);
|
||||||
|
|
||||||
match &mut sec.operation {
|
match &mut sec.operation {
|
||||||
Set(expr) => self.visit_expr(expr),
|
Set(expr) => self.visit_expr(expr),
|
||||||
Mut(expr) => self.visit_expr(expr),
|
Mut(expr) => self.visit_expr(expr),
|
||||||
Get => (),
|
Get => (),
|
||||||
}
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -881,23 +881,16 @@ impl<'a> Parser<'a> {
|
|||||||
|
|
||||||
pub fn parse_seq(&mut self) -> Result<Box<Expr>, SyntaxDiagnostic> {
|
pub fn parse_seq(&mut self) -> Result<Box<Expr>, SyntaxDiagnostic> {
|
||||||
let start = self.range();
|
let start = self.range();
|
||||||
|
|
||||||
self.eat_variant(Token::Bang)?;
|
self.eat_variant(Token::Bang)?;
|
||||||
|
|
||||||
let typ = self.parse_atom()?;
|
let typ = self.parse_atom()?;
|
||||||
|
|
||||||
let name = self.parse_atom()?;
|
let name = self.parse_atom()?;
|
||||||
|
|
||||||
let mut fields = vec![];
|
let mut fields = vec![];
|
||||||
|
|
||||||
let mut end = self.range();
|
let mut end = self.range();
|
||||||
|
|
||||||
while let Token::Dot = &self.get() {
|
while let Token::Dot = &self.get() {
|
||||||
self.advance();
|
self.advance();
|
||||||
end = self.range();
|
end = self.range();
|
||||||
fields.push(self.parse_id()?);
|
fields.push(self.parse_id()?);
|
||||||
}
|
}
|
||||||
|
|
||||||
let operation = if self.check_and_eat(Token::Eq) {
|
let operation = if self.check_and_eat(Token::Eq) {
|
||||||
let expr = self.parse_expr(false)?;
|
let expr = self.parse_expr(false)?;
|
||||||
end = expr.range;
|
end = expr.range;
|
||||||
@ -909,7 +902,6 @@ impl<'a> Parser<'a> {
|
|||||||
} else {
|
} else {
|
||||||
SeqOperation::Get
|
SeqOperation::Get
|
||||||
};
|
};
|
||||||
|
|
||||||
Ok(Box::new(Expr {
|
Ok(Box::new(Expr {
|
||||||
data: ExprKind::SeqRecord(
|
data: ExprKind::SeqRecord(
|
||||||
SeqRecord {
|
SeqRecord {
|
||||||
|
Loading…
Reference in New Issue
Block a user