22 using namespace llvm::codeview;
23 using namespace llvm::support;
28 return StringRef(reinterpret_cast<const char *>(LeafData.
data()),
38 bool FalseVal =
false;
43 if (Short < LF_NUMERIC) {
101 "Buffer contains invalid APSInt type");
121 "Data is not a numeric value!");
146 "Null terminated string buffer is empty!");
LLVM_NODISCARD LLVM_ATTRIBUTE_ALWAYS_INLINE StringRef take_back(size_t N=1) const
Return a StringRef equal to 'this' but with only the first N elements remaining.
Error consume(msf::StreamReader &Reader)
const unsigned char * bytes_end() const
uint64_t getLimitedValue(uint64_t Limit=~0ULL) const
If this value is smaller than the specified limit, return it, otherwise return the limit value...
Error readZeroString(StringRef &Dest)
bool isIntN(unsigned N) const
Check if this APInt has an N-bits unsigned integer value.
This file implements a class to represent arbitrary precision integral constant values and operations...
size_t size() const
size - Get the array size.
Error readInteger(uint8_t &Dest)
static ErrorSuccess success()
Create a success value.
Class for arbitrary precision integers.
LLVM_NODISCARD std::pair< StringRef, StringRef > split(char Separator) const
Split into two substrings around the first occurrence of a separator character.
StringRef getBytesAsCharacters(ArrayRef< uint8_t > LeafData)
Reinterpret a byte array as an array of characters.
StringRef getBytesAsCString(ArrayRef< uint8_t > LeafData)
Error consume_numeric(msf::StreamReader &Reader, uint64_t &Value)
Decodes a numeric leaf value that is known to be a particular type.
uint32_t bytesRemaining() const
const unsigned char * bytes_begin() const
Lightweight error class with error context and mandatory checking.
StringRef - Represent a constant reference to a string, i.e.