<- Back to shtanton's homepage
aboutsummaryrefslogtreecommitdiff
path: root/main
diff options
context:
space:
mode:
authorCharlie Stanton <charlie@shtanton.xyz>2023-04-25 09:56:00 +0100
committerCharlie Stanton <charlie@shtanton.xyz>2023-04-25 09:56:00 +0100
commitcce21232cc83060a53ecb3a7c30d7f6fbfd7a529 (patch)
tree5c562f71845615f324e3d450b4d4daeaad8dd54a /main
parent6ec9d0a831849ffaf7d46b2eb4db7d56260809cf (diff)
downloadstred-go-cce21232cc83060a53ecb3a7c30d7f6fbfd7a529.tar
Now uses a buffered output for writing to improve performance
Diffstat (limited to 'main')
-rw-r--r--main/main.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/main/main.go b/main/main.go
index e6730de..0c7324b 100644
--- a/main/main.go
+++ b/main/main.go
@@ -40,10 +40,11 @@ func main() {
program := Parse(tokens)
stdin := bufio.NewReader(os.Stdin)
+ stdout := bufio.NewWriter(os.Stdout)
state := ProgramState {
in: walk.NewJSONIn(stdin),
- out: walk.NewJSONOut(),
+ out: walk.NewJSONOut(stdout),
program: program,
}