Commit graph

3 commits

Author SHA1 Message Date
joeduffy
89f2424df1 Add a new harness for test cases
This adds a new test harness that will be used to run baseline-style
tests.  Each subdirectory underneath tests/output will be interpreted as
a test case, each of which can contain an optional `messages.txt` file
which will be compared as the expected output against the compiler's error
and warning messages, and/or an optional `Mu.out.json` file which will be
compared as the expected output against the compiler's output tree.

There's just a single "empty" test case for now.  I will start getting in
the habit of checking in a companion test for each AST kind we lower.
2017-01-08 15:20:46 -06:00
joeduffy
366648d1d4 Upgrade to latest TSLint, and compile cleanly 2016-12-31 11:16:36 -08:00
joeduffy
a2c376b9ed Implement the MuIL AST
This is an initial implementation of the MuIL AST.

The AST has been intentionally pared back to the bare essentials, leaving the
task of lowering to the higher level MetaMu compilers.  For example, there is
only a single conditional statement, a single looping construct, etc.

It is in the MuJS compiler package so that we can begin lowering TypeScript
ASTs to this format and serializing them.  We will need separate Go projections
of these shapes in order to deserialize and evaluate programs to produce MuGL
from within the runtime/evaluation engine.

I'm sure the shape of these things will need to change -- and there are a
handful of open questions -- however, this is a start...
2016-12-30 15:34:49 -08:00