OSDN Git Service

Create a TempFile class.
authorRafael Espindola <rafael.espindola@gmail.com>
Mon, 13 Nov 2017 18:33:44 +0000 (18:33 +0000)
committerRafael Espindola <rafael.espindola@gmail.com>
Mon, 13 Nov 2017 18:33:44 +0000 (18:33 +0000)
commit8adf022a730be6eb14b7006fc36b64346060be23
tree1971197c22baec9b84f64a8e15c0714f70488f45
parented22c2369258e7e9a9bf3ded3ccf1a7b780a2a51
Create a TempFile class.

This just adds a TempFile class and replaces the use in
FileOutputBuffer with it.

The only difference for now is better error handling. Followup work includes:

- Convert other user of temporary files to it.
- Add support for automatically deleting on windows.
- Add a createUnnamed method that returns a potentially unnamed
  file. It would be actually unnamed on modern linux and have a
  unknown name on windows.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@318069 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/Support/FileSystem.h
lib/Support/FileOutputBuffer.cpp
lib/Support/Path.cpp