LLVM  14.0.0git
Classes | Public Member Functions | List of all members
llvm::ToolOutputFile Class Reference

This class contains a raw_fd_ostream and adds a few extra features commonly needed for compiler-like tool output files: More...

#include "llvm/Support/ToolOutputFile.h"

Public Member Functions

 ToolOutputFile (StringRef Filename, std::error_code &EC, sys::fs::OpenFlags Flags)
 This constructor's arguments are passed to raw_fd_ostream's constructor. More...
 
 ToolOutputFile (StringRef Filename, int FD)
 
raw_fd_ostreamos ()
 Return the contained raw_fd_ostream. More...
 
StringRef getFilename ()
 Return the filename initialized with. More...
 
void keep ()
 Indicate that the tool's job wrt this output file has been successful and the file should not be deleted. More...
 

Detailed Description

This class contains a raw_fd_ostream and adds a few extra features commonly needed for compiler-like tool output files:

Definition at line 26 of file ToolOutputFile.h.

Constructor & Destructor Documentation

◆ ToolOutputFile() [1/2]

ToolOutputFile::ToolOutputFile ( StringRef  Filename,
std::error_code &  EC,
sys::fs::OpenFlags  Flags 
)

This constructor's arguments are passed to raw_fd_ostream's constructor.

Definition at line 41 of file ToolOutputFile.cpp.

References isStdout(), and llvm::outs().

◆ ToolOutputFile() [2/2]

ToolOutputFile::ToolOutputFile ( StringRef  Filename,
int  FD 
)

Definition at line 56 of file ToolOutputFile.cpp.

Member Function Documentation

◆ getFilename()

StringRef llvm::ToolOutputFile::getFilename ( )
inline

Return the filename initialized with.

Definition at line 62 of file ToolOutputFile.h.

◆ keep()

void llvm::ToolOutputFile::keep ( )
inline

Indicate that the tool's job wrt this output file has been successful and the file should not be deleted.

Definition at line 66 of file ToolOutputFile.h.

Referenced by createDependencyFile(), llvm::TableGenMain(), and llvm::LTOCodeGenerator::writeMergedModules().

◆ os()

raw_fd_ostream& llvm::ToolOutputFile::os ( )
inline

The documentation for this class was generated from the following files: