From aa821e720a86309854d0d6ba31723e94c96506fb Mon Sep 17 00:00:00 2001 From: greg Date: Thu, 21 Dec 2017 01:10:53 -0800 Subject: [PATCH] Apply wokr --- src/rukka_lang/mod.rs | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/src/rukka_lang/mod.rs b/src/rukka_lang/mod.rs index 9d15006..a925295 100644 --- a/src/rukka_lang/mod.rs +++ b/src/rukka_lang/mod.rs @@ -182,8 +182,17 @@ impl EvaluatorState { }) } - fn apply(&mut self, _function: Sexp, _operands: Sexp) -> Result { - Err(format!("Not implemented")) + fn apply(&mut self, function: Sexp, _operands: Sexp) -> Result { + use self::Sexp::*; + match function { + FnLiteral { formal_params, body } => { + Err(format!("unimplementd")) + }, + Builtin(sym) => { + Err(format!("unimplementd")) + }, + _ => return Err(format!("Bad type to apply")), + } } }