From: Ian Lance Taylor Date: Fri, 3 Aug 2018 16:55:44 +0000 (-0700) Subject: os: document that Remove removes only empty directories X-Git-Tag: go1.11rc1~50 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=0bad63437ec0262c309efd4262b86352a25a73e3;p=gostls13.git os: document that Remove removes only empty directories Fixes #26507 Change-Id: I967e4f897ca891c70ca8bb0e66b984530c240815 Reviewed-on: https://go-review.googlesource.com/127835 Reviewed-by: Brad Fitzpatrick Reviewed-by: Rob Pike --- diff --git a/src/os/file_unix.go b/src/os/file_unix.go index 4f80553a18..cb90b70735 100644 --- a/src/os/file_unix.go +++ b/src/os/file_unix.go @@ -296,7 +296,7 @@ func Truncate(name string, size int64) error { return nil } -// Remove removes the named file or directory. +// Remove removes the named file or (empty) directory. // If there is an error, it will be of type *PathError. func Remove(name string) error { // System call interface forces us to know