4 ms·
Neat work! Also good demonstration of new C# 7.0 features.
by hestefisk 8y ago
Neat work! Also good demonstration of new C# 7.0 features.
- suzuki 8y agoThank you. I appreciated especially the pattern matching feature of C# 7 while programming the interpreter. For example: /// <summary>Evaluate a Lisp expression in an environment.</summary> public object Eval(object x, Cell env) { try { for (;;) { switch (x) { case Arg xarg: return xarg.GetValue(env); case Sym xsym: try { return Globals[xsym]; } catch (KeyNotFoundException) { throw new EvalException("void variable", x); } case Cell xcell: