diff options
Diffstat (limited to 'gopher')
-rw-r--r-- | gopher/gophermap/parse.go | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/gopher/gophermap/parse.go b/gopher/gophermap/parse.go index 17fe833..3317514 100644 --- a/gopher/gophermap/parse.go +++ b/gopher/gophermap/parse.go @@ -16,9 +16,7 @@ func Parse(input io.Reader) (gopher.MapDocument, error) { rdr := bufio.NewReader(input) doc := gopher.MapDocument{} - num := 0 - for { - num += 1 + for num := 1; ; num += 1 { line, err := rdr.ReadBytes('\n') isEOF := errors.Is(err, io.EOF) if err != nil && !isEOF { |