From: Rob Pike Date: Wed, 14 Sep 2011 18:18:43 +0000 (-0700) Subject: path/filepath: document that Walk sorts its output X-Git-Tag: weekly.2011-09-16~29 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=7edfcede1303b498b55d261d35eb4c98901edc4b;p=gostls13.git path/filepath: document that Walk sorts its output R=golang-dev, cw CC=golang-dev https://golang.org/cl/5004045 --- diff --git a/src/pkg/path/filepath/path.go b/src/pkg/path/filepath/path.go index 668d20fa13..c40d9ff564 100644 --- a/src/pkg/path/filepath/path.go +++ b/src/pkg/path/filepath/path.go @@ -302,7 +302,9 @@ func walk(path string, info *os.FileInfo, walkFn WalkFunc) os.Error { // Walk walks the file tree rooted at root, calling walkFn for each file or // directory in the tree, including root. All errors that arise visiting files -// and directories are filtered by walkFn. +// and directories are filtered by walkFn. The files are walked in lexical +// order, which makes the output deterministic but means that for very +// large directories Walk can be inefficient. func Walk(root string, walkFn WalkFunc) os.Error { info, err := os.Lstat(root) if err != nil {