get the basic add example working

This commit is contained in:
Michael McLoughlin
2018-12-08 22:02:02 -08:00
parent 5431f2edef
commit 20525e1437
4 changed files with 63 additions and 9 deletions

View File

@@ -6,6 +6,7 @@ import (
"log"
"github.com/mmcloughlin/avo/gotypes"
"github.com/mmcloughlin/avo/pass"
"github.com/mmcloughlin/avo"
"github.com/mmcloughlin/avo/reg"
@@ -84,6 +85,11 @@ func (c *Context) Main(wout, werr io.Writer) int {
return 1
}
if err := pass.Compile.Execute(f); err != nil {
diag.Println(err)
return 1
}
p := avo.NewGoPrinter(wout)
if err := p.Print(f); err != nil {
diag.Println(err)