diff --git a/src/ast/desugar.rs b/src/ast/desugar.rs index 9b4349b6..0f95c693 100644 --- a/src/ast/desugar.rs +++ b/src/ast/desugar.rs @@ -373,31 +373,6 @@ impl Desugar { .map_err(|e| e.map_token(|tok| tok.to_string()))?) } - // TODO declare by creating a new global function. See issue #334 - pub fn declare(&mut self, span: Span, name: Symbol, sort: Symbol) -> Vec { - let fresh = self.get_fresh(); - vec![ - NCommand::Function(FunctionDecl { - name: fresh, - schema: Schema { - input: vec![], - output: sort, - }, - default: None, - merge: None, - merge_action: Actions::default(), - cost: None, - unextractable: false, - ignore_viz: false, - }), - NCommand::CoreAction(Action::Let( - span.clone(), - name, - Expr::Call(span.clone(), fresh, vec![]), - )), - ] - } - pub fn desugar_function(&mut self, fdecl: &FunctionDecl) -> Vec { vec![NCommand::Function(FunctionDecl { name: fdecl.name,