[Rd] typo in docs for unlink()

From: Tony Plate <tplate_at_acm.org>
Date: Tue, 10 Nov 2009 20:52:45 -0700


The VALUE section in the help for 'unlink' says:

| 0| for success, |1| for failure. Not deleting a non-existent file is not a failure, nor is being unable to delete a directory if |recursive = FALSE|. However, missing values in |x| result are regarded as failures.

The last phrase doesn't make sense to me. Should it be either "missing values in x are regarded as failures" or "missing values in x result in failure" ?

Also, after reading the docs, I'm still unable to work out if unlink() will return 1 when the user tries to recursively delete a directory on systems that don't support recursive=T.

The DETAILS section says "recursive=TRUE is not supported on all platforms, and may be ignored, with a warning", which could be interpreted as implying no special action when recursive=TRUE is not implemented (other than a warning()), and the VALUE section doesn't say what the return value will be under such conditions.

I've skimmed the various *_unlink functions in src/main/platform.c, and it looks like they all implement recursive=TRUE, so I'm still in the dark about the required behavior on systems that don't support it. Could this be clarified in the help file?

thanks,

Tony Plate



R-devel_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel Received on Wed 11 Nov 2009 - 03:56:29 GMT

This archive was generated by hypermail 2.2.0 : Thu 12 Nov 2009 - 14:40:23 GMT