LLVM: llvm::RecordVal Class Reference (original) (raw)

This class represents a field in a record, including its name, type, value, and source location. More...

#include "[llvm/TableGen/Record.h](TableGen%5F2Record%5F8h%5Fsource.html)"

Public Member Functions
RecordVal (const Init *N, const RecTy *T, FieldKind K)
RecordVal (const Init *N, SMLoc Loc, const RecTy *T, FieldKind K)
RecordKeeper & getRecordKeeper () const
Get the record keeper used to unique this value.
StringRef getName () const
Get the name of the field as a StringRef.
const Init * getNameInit () const
Get the name of the field as an Init.
std::string getNameInitAsString () const
Get the name of the field as a std::string.
const SMLoc & getLoc () const
Get the source location of the point where the field was defined.
bool isNonconcreteOK () const
Is this a field where nonconcrete values are okay?
bool isTemplateArg () const
Is this a template argument?
const RecTy * getType () const
Get the type of the field value as a RecTy.
std::string getPrintType () const
Get the type of the field for printing purposes.
const Init * getValue () const
Get the value of the field as an Init.
bool setValue (const Init *V)
Set the value of the field from an Init.
bool setValue (const Init *V, SMLoc NewLoc)
Set the value and source location of the field.
void addReferenceLoc (SMRange Loc)
Add a reference to this record value.
ArrayRef< SMRange > getReferenceLocs () const
Return the references of this record value.
void setUsed (bool Used)
Whether this value is used.
bool isUsed () const
void dump () const
void print (raw_ostream &OS, bool PrintSem=true) const
Print the value to an output stream, possibly with a semicolon.

This class represents a field in a record, including its name, type, value, and source location.

Definition at line 1508 of file Record.h.

FieldKind

Enumerator
FK_Normal
FK_NonconcreteOK
FK_TemplateArg

Definition at line 1512 of file Record.h.

RecordVal() [2/2]

addReferenceLoc()

void llvm::RecordVal::addReferenceLoc ( SMRange Loc) inline

dump()

getLoc()

const SMLoc & llvm::RecordVal::getLoc ( ) const inline

getName()

getNameInit()

const Init * llvm::RecordVal::getNameInit ( ) const inline

getNameInitAsString()

std::string llvm::RecordVal::getNameInitAsString ( ) const inline

getPrintType()

std::string RecordVal::getPrintType ( ) const

getRecordKeeper()

RecordKeeper & llvm::RecordVal::getRecordKeeper ( ) const inline

getReferenceLocs()

Return the references of this record value.

Definition at line 1578 of file Record.h.

getType()

const RecTy * llvm::RecordVal::getType ( ) const inline

getValue()

const Init * llvm::RecordVal::getValue ( ) const inline

isNonconcreteOK()

bool llvm::RecordVal::isNonconcreteOK ( ) const inline

isTemplateArg()

bool llvm::RecordVal::isTemplateArg ( ) const inline

isUsed()

bool llvm::RecordVal::isUsed ( ) const inline

print()

setUsed()

void llvm::RecordVal::setUsed ( bool Used) inline

Whether this value is used.

Useful for reporting warnings, for example when a template argument is unused.

Definition at line 1582 of file Record.h.

Referenced by llvm::TGVarScope::getVar().

setValue() [1/2]

setValue() [2/2]

Record


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