Add unfolded generation of lua for better performance
This commit is contained in:
parent
aae20662e2
commit
3f0793ca22
42 changed files with 7629 additions and 325 deletions
|
@ -79,10 +79,11 @@ namespace AspectedRouting.Test
|
|||
public void EitherFunc_SpecializeToString_Const()
|
||||
{
|
||||
var a = new Constant("a");
|
||||
|
||||
var mconst = new Apply(new Apply(Funcs.EitherFunc, Funcs.Id), Funcs.Const);
|
||||
var specialized = new Apply(mconst, a).Specialize(Typs.String);
|
||||
|
||||
Assert.Equal("((($const $id) $const) \"a\")", specialized.ToString());
|
||||
Assert.Equal("((($firstArg $id) $firstArg) \"a\")", specialized.ToString());
|
||||
Assert.Equal("string; $b -> string", string.Join("; ", new Apply(mconst, a).Types));
|
||||
Assert.Equal("\"a\"", specialized.Evaluate(null).Pretty());
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue