LLVM  13.0.0git
Macros
YAMLTraits.h File Reference
#include "llvm/ADT/Optional.h"
#include "llvm/ADT/SmallVector.h"
#include "llvm/ADT/StringExtras.h"
#include "llvm/ADT/StringMap.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/ADT/Twine.h"
#include "llvm/Support/AlignOf.h"
#include "llvm/Support/Allocator.h"
#include "llvm/Support/Endian.h"
#include "llvm/Support/Regex.h"
#include "llvm/Support/SMLoc.h"
#include "llvm/Support/SourceMgr.h"
#include "llvm/Support/VersionTuple.h"
#include "llvm/Support/YAMLParser.h"
#include "llvm/Support/raw_ostream.h"
#include <cassert>
#include <cctype>
#include <cstddef>
#include <cstdint>
#include <iterator>
#include <map>
#include <memory>
#include <new>
#include <string>
#include <system_error>
#include <type_traits>
#include <vector>
Include dependency graph for YAMLTraits.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define LLVM_YAML_STRONG_TYPEDEF(_base, _type)
 
#define LLVM_YAML_IS_SEQUENCE_VECTOR_IMPL(TYPE, FLOW)
 
#define LLVM_YAML_IS_SEQUENCE_VECTOR(type)   LLVM_YAML_IS_SEQUENCE_VECTOR_IMPL(type, false)
 
#define LLVM_YAML_IS_FLOW_SEQUENCE_VECTOR(type)   LLVM_YAML_IS_SEQUENCE_VECTOR_IMPL(type, true)
 
#define LLVM_YAML_DECLARE_MAPPING_TRAITS(Type)
 
#define LLVM_YAML_DECLARE_ENUM_TRAITS(Type)
 
#define LLVM_YAML_DECLARE_BITSET_TRAITS(Type)
 
#define LLVM_YAML_DECLARE_SCALAR_TRAITS(Type, MustQuote)
 
#define LLVM_YAML_IS_DOCUMENT_LIST_VECTOR(_type)
 
#define LLVM_YAML_IS_STRING_MAP(_type)
 

Macro Definition Documentation

◆ LLVM_YAML_DECLARE_BITSET_TRAITS

#define LLVM_YAML_DECLARE_BITSET_TRAITS (   Type)
Value:
namespace llvm { \
namespace yaml { \
template <> struct ScalarBitSetTraits<Type> { \
static void bitset(IO &IO, Type &Options); \
}; \
} \
}

◆ LLVM_YAML_DECLARE_ENUM_TRAITS

#define LLVM_YAML_DECLARE_ENUM_TRAITS (   Type)
Value:
namespace llvm { \
namespace yaml { \
template <> struct ScalarEnumerationTraits<Type> { \
static void enumeration(IO &io, Type &Value); \
}; \
} \
}

◆ LLVM_YAML_DECLARE_MAPPING_TRAITS

#define LLVM_YAML_DECLARE_MAPPING_TRAITS (   Type)
Value:
namespace llvm { \
namespace yaml { \
template <> struct MappingTraits<Type> { \
static void mapping(IO &IO, Type &Obj); \
}; \
} \
}

◆ LLVM_YAML_DECLARE_SCALAR_TRAITS

#define LLVM_YAML_DECLARE_SCALAR_TRAITS (   Type,
  MustQuote 
)
Value:
namespace llvm { \
namespace yaml { \
template <> struct ScalarTraits<Type> { \
static void output(const Type &Value, void *ctx, raw_ostream &Out); \
static StringRef input(StringRef Scalar, void *ctxt, Type &Value); \
static QuotingType mustQuote(StringRef) { return MustQuote; } \
}; \
} \
}

◆ LLVM_YAML_IS_DOCUMENT_LIST_VECTOR

#define LLVM_YAML_IS_DOCUMENT_LIST_VECTOR (   _type)
Value:
namespace llvm { \
namespace yaml { \
template <unsigned N> \
struct DocumentListTraits<SmallVector<_type, N>> \
: public SequenceTraitsImpl<SmallVector<_type, N>, false> {}; \
template <> \
struct DocumentListTraits<std::vector<_type>> \
: public SequenceTraitsImpl<std::vector<_type>, false> {}; \
} \
}

◆ LLVM_YAML_IS_FLOW_SEQUENCE_VECTOR

#define LLVM_YAML_IS_FLOW_SEQUENCE_VECTOR (   type)    LLVM_YAML_IS_SEQUENCE_VECTOR_IMPL(type, true)

◆ LLVM_YAML_IS_SEQUENCE_VECTOR

#define LLVM_YAML_IS_SEQUENCE_VECTOR (   type)    LLVM_YAML_IS_SEQUENCE_VECTOR_IMPL(type, false)

◆ LLVM_YAML_IS_SEQUENCE_VECTOR_IMPL

#define LLVM_YAML_IS_SEQUENCE_VECTOR_IMPL (   TYPE,
  FLOW 
)
Value:
namespace llvm { \
namespace yaml { \
static_assert( \
!std::is_fundamental<TYPE>::value && \
!std::is_same<TYPE, std::string>::value && \
!std::is_same<TYPE, llvm::StringRef>::value, \
"only use LLVM_YAML_IS_SEQUENCE_VECTOR for types you control"); \
template <> struct SequenceElementTraits<TYPE> { \
static const bool flow = FLOW; \
}; \
} \
}

◆ LLVM_YAML_IS_STRING_MAP

#define LLVM_YAML_IS_STRING_MAP (   _type)
Value:
namespace llvm { \
namespace yaml { \
template <> \
struct CustomMappingTraits<std::map<std::string, _type>> \
: public StdMapStringCustomMappingTraitsImpl<_type> {}; \
} \
}

◆ LLVM_YAML_STRONG_TYPEDEF

#define LLVM_YAML_STRONG_TYPEDEF (   _base,
  _type 
)
Value:
struct _type { \
_type() = default; \
_type(const _base v) : value(v) {} \
_type(const _type &v) = default; \
_type &operator=(const _type &rhs) = default; \
_type &operator=(const _base &rhs) { value = rhs; return *this; } \
operator const _base & () const { return value; } \
bool operator==(const _type &rhs) const { return value == rhs.value; } \
bool operator==(const _base &rhs) const { return value == rhs; } \
bool operator<(const _type &rhs) const { return value < rhs.value; } \
_base value; \
using BaseType = _base; \
};
llvm
---------------------— PointerInfo ------------------------------------—
Definition: AllocatorList.h:23
output
Current output
Definition: README.txt:1350
BaseType
Options
const char LLVMTargetMachineRef LLVMPassBuilderOptionsRef Options
Definition: PassBuilderBindings.cpp:48
input
The initial backend is deliberately restricted to z10 We should add support for later architectures at some point If an asm ties an i32 r result to an i64 input
Definition: README.txt:10
TemplateParamKind::Type
@ Type
operator==
bool operator==(const StringView &LHS, const StringView &RHS)
Definition: StringView.h:112
operator<
bool operator<(const DeltaInfo &LHS, int64_t Delta)
Definition: LineTable.cpp:30
llvm::TargetStackID::Value
Value
Definition: TargetFrameLowering.h:27