add take left operator, sizecoded wasm4 skip ahead to 512 bytes

This commit is contained in:
2021-11-11 21:20:18 +01:00
parent ee746d1cea
commit d3e882cba0
6 changed files with 74 additions and 32 deletions

View File

@@ -675,7 +675,14 @@ fn script_parser() -> impl Parser<Token, ast::Script, Error = Simple<Token>> + C
})
.boxed();
op_bit
let op_first = op_bit.clone().then(
just(Token::Op("<|".to_string())).ignore_then(op_bit).repeated()
).foldl(|left, right| {
let span = left.span.start..right.span.end;
ast::Expr::First { value: Box::new(left), drop: Box::new(right) }.with_span(span)
}).boxed();
op_first
});
expression_out = Some(expression.clone());