aboutsummaryrefslogtreecommitdiffstats
path: root/core/vm/sqlvm/cmd
diff options
context:
space:
mode:
Diffstat (limited to 'core/vm/sqlvm/cmd')
-rw-r--r--core/vm/sqlvm/cmd/ast-printer/main.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/core/vm/sqlvm/cmd/ast-printer/main.go b/core/vm/sqlvm/cmd/ast-printer/main.go
index 7b4251fa1..6965a1d4e 100644
--- a/core/vm/sqlvm/cmd/ast-printer/main.go
+++ b/core/vm/sqlvm/cmd/ast-printer/main.go
@@ -3,6 +3,7 @@ package main
import (
"flag"
"fmt"
+ "os"
"github.com/dexon-foundation/dexon/core/vm/sqlvm/ast"
"github.com/dexon-foundation/dexon/core/vm/sqlvm/parser"
@@ -17,7 +18,7 @@ func main() {
n, err := parser.Parse([]byte(flag.Arg(0)))
fmt.Printf("detail: %t\n", detail)
if err == nil {
- ast.PrintAST(n, "", detail)
+ ast.PrintAST(os.Stdout, n, " ", detail)
} else {
fmt.Printf("err:\n%+v\n", err)
}