summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDimitri Sokolyuk <demon@dim13.org>2018-09-23 13:20:02 +0200
committerDimitri Sokolyuk <demon@dim13.org>2018-09-23 13:20:02 +0200
commit65824e4d38828a2b9b6068f915e24a830823637d (patch)
tree6bb9c9f4e6ef33b7dd05bbd7e55a2c407eaffa1a
parent45a968cb94598074e608c17161d475911f7e0871 (diff)
..
-rw-r--r--go/forth/forth.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/go/forth/forth.go b/go/forth/forth.go
index 5ae7805..c31988d 100644
--- a/go/forth/forth.go
+++ b/go/forth/forth.go
@@ -155,13 +155,14 @@ func compile(dict dictionary, l *lexer) ([]word, error) {
var words []word
for !l.atEOL() {
v := l.next()
- // colon operator
+ // colon operator, switch to compile mode
if v == ":" {
if err := colon(dict, l); err != nil {
return nil, err
}
continue
}
+ // semicolon, should be compile only word
if v == ";" {
break
}