summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Support/Unix/PathV2.inc
diff options
context:
space:
mode:
authorMichael J. Spencer <bigcheesegs@gmail.com>2010-12-07 01:23:08 +0000
committerMichael J. Spencer <bigcheesegs@gmail.com>2010-12-07 01:23:08 +0000
commit5529c57cfe39cbbd8c81dc0d8da9d61196ca71cd (patch)
tree74e11239604934cba006eaa7682b3d198d324f79 /llvm/lib/Support/Unix/PathV2.inc
parent20daa28344d24e9e6f72140c7eca220dfe56b7cd (diff)
downloadbcm5719-llvm-5529c57cfe39cbbd8c81dc0d8da9d61196ca71cd.tar.gz
bcm5719-llvm-5529c57cfe39cbbd8c81dc0d8da9d61196ca71cd.zip
Support/PathV2: Clarify and correct documentation.
llvm-svn: 121091
Diffstat (limited to 'llvm/lib/Support/Unix/PathV2.inc')
-rw-r--r--llvm/lib/Support/Unix/PathV2.inc5
1 files changed, 5 insertions, 0 deletions
diff --git a/llvm/lib/Support/Unix/PathV2.inc b/llvm/lib/Support/Unix/PathV2.inc
index f7ca64daf7e..4ca482dfce1 100644
--- a/llvm/lib/Support/Unix/PathV2.inc
+++ b/llvm/lib/Support/Unix/PathV2.inc
@@ -30,6 +30,11 @@
using namespace llvm;
namespace {
+ /// This class automatically closes the given file descriptor when it goes out
+ /// of scope. You can take back explicit ownership of the file descriptor by
+ /// calling take(). The destructor does not verify that close was successful.
+ /// Therefore, never allow this class to call close on a file descriptor that
+ /// has been read from or written to.
struct AutoFD {
int FileDescriptor;
OpenPOWER on IntegriCloud