From: Jeff R. Allen Date: Fri, 17 Jul 2015 14:33:51 +0000 (+0200) Subject: os: improve documentation on Rename X-Git-Tag: go1.5beta3~169 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=fb90f4c1c2a966efb3ec2af48738ad9075dee229;p=gostls13.git os: improve documentation on Rename Rename should document that it returns *LinkError, like Create and Stat do. Fixes #10061 Change-Id: I7bfe8b0267f6c4a57dd6b26cba44928714711724 Reviewed-on: https://go-review.googlesource.com/12353 Reviewed-by: Brad Fitzpatrick --- diff --git a/src/os/file.go b/src/os/file.go index f332bc8346..f1366110cc 100644 --- a/src/os/file.go +++ b/src/os/file.go @@ -259,6 +259,7 @@ func Create(name string) (file *File, err error) { var lstat = Lstat // Rename renames (moves) a file. OS-specific restrictions might apply. +// If there is an error, it will be of type *LinkError. func Rename(oldpath, newpath string) error { return rename(oldpath, newpath) }