From: Brad Fitzpatrick Date: Fri, 9 Dec 2016 04:08:32 +0000 (+0000) Subject: go/build: clarify Context.HasSubdir docs X-Git-Tag: go1.8beta2~54 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=3c0466136d635fc4845484f0a98f52e66d61168b;p=gostls13.git go/build: clarify Context.HasSubdir docs Fixes #17888 Change-Id: I7490b95a03b810a0f7ed1f07f37d7c7b3ac036be Reviewed-on: https://go-review.googlesource.com/34240 Reviewed-by: Dmitri Shuralyov Reviewed-by: Joe Tsai --- diff --git a/src/go/build/build.go b/src/go/build/build.go index f6aabcb3af..ea37bbbcb5 100644 --- a/src/go/build/build.go +++ b/src/go/build/build.go @@ -76,8 +76,9 @@ type Context struct { // If IsDir is nil, Import calls os.Stat and uses the result's IsDir method. IsDir func(path string) bool - // HasSubdir reports whether dir is a subdirectory of - // (perhaps multiple levels below) root. + // HasSubdir reports whether dir is lexically a subdirectory of + // root, perhaps multiple levels below. It does not try to check + // whether dir exists. // If so, HasSubdir sets rel to a slash-separated path that // can be joined to root to produce a path equivalent to dir. // If HasSubdir is nil, Import uses an implementation built on