Diff
Not logged in

Differences From Artifact [5b490c90826e242f]:

To Artifact [bcefce47daacc4a5]:


5 * Evaluator for Polemy programming language. 5 * Evaluator for Polemy programming language. 6 */ 6 */ 7 module polemy.eval; 7 module polemy.eval; 8 import polemy._common; 8 import polemy._common; 9 import polemy.lex : LexPosition; 9 import polemy.lex : LexPosition; 10 import polemy.ast; 10 import polemy.ast; 11 import polemy.parse; 11 import polemy.parse; 12 import polemy.runtime; | 12 import polemy.value; 13 import std.typecons; 13 import std.typecons; 14 import std.stdio; 14 import std.stdio; 15 15 16 Context createGlobalContext() 16 Context createGlobalContext() 17 { 17 { 18 auto ctx = new Context; 18 auto ctx = new Context; 19 ctx.add("+", new FunValue(delegate Value(immutable LexPosition pos, Valu 19 ctx.add("+", new FunValue(delegate Value(immutable LexPosition pos, Valu