diff --git a/src/protocol/parser/pass_rewriting.rs b/src/protocol/parser/pass_rewriting.rs index 724f9d0c42354424329169b1510e4520b4720c19..5884cdca726ff74bb13f9733d73ab3bd8e5f8f6d 100644 --- a/src/protocol/parser/pass_rewriting.rs +++ b/src/protocol/parser/pass_rewriting.rs @@ -294,35 +294,6 @@ impl Visitor for PassRewriting { } } -impl PassRewriting { - fn create_runtime_call_statement(&self, ctx: &mut Ctx, method: Method, arguments: Vec) -> (CallExpressionId, ExpressionStatementId) { - let call_expr_id = ctx.heap.alloc_call_expression(|this| CallExpression{ - this, - func_span: InputSpan::new(), - full_span: InputSpan::new(), - parser_type: ParserType{ - elements: Vec::new(), - full_span: InputSpan::new(), - }, - method, - arguments, - procedure: ProcedureDefinitionId::new_invalid(), - parent: ExpressionParent::None, - }); - let call_stmt_id = ctx.heap.alloc_expression_statement(|this| ExpressionStatement{ - this, - span: InputSpan::new(), - expression: call_expr_id.upcast(), - next: StatementId::new_invalid(), - }); - - let call_expr = &mut ctx.heap[call_expr_id]; - call_expr.parent = ExpressionParent::ExpressionStmt(call_stmt_id); - - return (call_expr_id, call_stmt_id); - } -} - // ----------------------------------------------------------------------------- // Utilities to create compiler-generated AST nodes // -----------------------------------------------------------------------------