9#ifndef LLVM_OBJECTYAML_YAML_H
10#define LLVM_OBJECTYAML_YAML_H
72 bool DataIsHexString =
true;
83 return Data.
size() / 2;
101 if (
LHS.Data.empty() &&
RHS.Data.empty())
104 return LHS.DataIsHexString ==
RHS.DataIsHexString &&
LHS.Data ==
RHS.Data;
ArrayRef - Represent a constant reference to an array (0 or more elements consecutively in memory),...
size_t size() const
size - Get the array size.
StringRef - Represent a constant reference to a string, i.e.
This class implements an extremely fast bulk output stream that can only output to a stream.
Specialized YAMLIO scalar type for representing a binary blob.
ArrayRef< uint8_t >::size_type binary_size() const
The number of bytes that are represented by this BinaryRef.
BinaryRef(StringRef Data)
friend bool operator==(const BinaryRef &LHS, const BinaryRef &RHS)
BinaryRef(ArrayRef< uint8_t > Data)
LLVM_ABI void writeAsHex(raw_ostream &OS) const
Write the contents (regardless of whether it is binary or a hex string) as hex to the given raw_ostre...
LLVM_ABI void writeAsBinary(raw_ostream &OS, uint64_t N=UINT64_MAX) const
Write the contents (regardless of whether it is binary or a hex string) as binary to the given raw_os...
bool operator==(const BinaryRef &LHS, const BinaryRef &RHS)
QuotingType
Describe which type of quotes should be used when quoting is necessary.
QuotingType needsQuotes(StringRef S, bool ForcePreserveAsString=true)
This is an optimization pass for GlobalISel generic memory operations.
ArrayRef< CharT > arrayRefFromStringRef(StringRef Input)
Construct a string ref from an array ref of unsigned chars.
static LLVM_ABI void output(const BinaryRef &, void *, raw_ostream &)
static LLVM_ABI StringRef input(StringRef, void *, BinaryRef &)
static QuotingType mustQuote(StringRef S)
This class should be specialized by type that requires custom conversion to/from a yaml scalar.