LLVM
13.0.0git
lib
TextAPI
MachO
TextStubCommon.h
Go to the documentation of this file.
1
//===- TextStubCommon.h ---------------------------------------------------===//
2
//
3
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4
// See https://llvm.org/LICENSE.txt for license information.
5
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6
//
7
//===----------------------------------------------------------------------===//
8
//
9
// Defines common Text Stub YAML mappings.
10
//
11
//===----------------------------------------------------------------------===//
12
13
#ifndef LLVM_TEXTAPI_TEXT_STUB_COMMON_H
14
#define LLVM_TEXTAPI_TEXT_STUB_COMMON_H
15
16
#include "
llvm/ADT/StringRef.h
"
17
#include "
llvm/Support/YAMLTraits.h
"
18
#include "
llvm/TextAPI/MachO/Architecture.h
"
19
#include "
llvm/TextAPI/MachO/ArchitectureSet.h
"
20
#include "
llvm/TextAPI/MachO/InterfaceFile.h
"
21
#include "
llvm/TextAPI/MachO/PackedVersion.h
"
22
23
using
UUID
= std::pair<llvm::MachO::Target, std::string>;
24
25
LLVM_YAML_STRONG_TYPEDEF
(
llvm::StringRef
, FlowStringRef)
26
LLVM_YAML_STRONG_TYPEDEF
(uint8_t, SwiftVersion)
27
LLVM_YAML_IS_FLOW_SEQUENCE_VECTOR
(
UUID
)
28
LLVM_YAML_IS_FLOW_SEQUENCE_VECTOR
(FlowStringRef)
29
30
namespace
llvm
{
31
namespace
yaml {
32
33
template
<>
struct
ScalarTraits<FlowStringRef> {
34
static
void
output
(
const
FlowStringRef &,
void
*,
raw_ostream
&);
35
static
StringRef
input
(
StringRef
,
void
*, FlowStringRef &);
36
static
QuotingType mustQuote(
StringRef
);
37
};
38
39
template
<>
struct
ScalarEnumerationTraits<MachO::
ObjCConstraintType
> {
40
static
void
enumeration(IO &,
MachO::ObjCConstraintType
&);
41
};
42
43
template
<>
struct
ScalarTraits<MachO::
PlatformSet
> {
44
static
void
output
(
const
MachO::PlatformSet
&,
void
*,
raw_ostream
&);
45
static
StringRef
input
(
StringRef
,
void
*,
MachO::PlatformSet
&);
46
static
QuotingType mustQuote(
StringRef
);
47
};
48
49
template
<>
struct
ScalarBitSetTraits<MachO::ArchitectureSet> {
50
static
void
bitset(IO &,
MachO::ArchitectureSet
&);
51
};
52
53
template
<>
struct
ScalarTraits<MachO::
Architecture
> {
54
static
void
output
(
const
MachO::Architecture
&,
void
*,
raw_ostream
&);
55
static
StringRef
input
(
StringRef
,
void
*,
MachO::Architecture
&);
56
static
QuotingType mustQuote(
StringRef
);
57
};
58
59
template
<>
struct
ScalarTraits<MachO::PackedVersion> {
60
static
void
output
(
const
MachO::PackedVersion
&,
void
*,
raw_ostream
&);
61
static
StringRef
input
(
StringRef
,
void
*,
MachO::PackedVersion
&);
62
static
QuotingType mustQuote(
StringRef
);
63
};
64
65
template
<>
struct
ScalarTraits<SwiftVersion> {
66
static
void
output
(
const
SwiftVersion &,
void
*,
raw_ostream
&);
67
static
StringRef
input
(
StringRef
,
void
*, SwiftVersion &);
68
static
QuotingType mustQuote(
StringRef
);
69
};
70
71
template
<>
struct
ScalarTraits<
UUID
> {
72
static
void
output
(
const
UUID
&,
void
*,
raw_ostream
&);
73
static
StringRef
input
(
StringRef
,
void
*,
UUID
&);
74
static
QuotingType mustQuote(
StringRef
);
75
};
76
77
}
// end namespace yaml.
78
}
// end namespace llvm.
79
80
#endif // LLVM_TEXTAPI_TEXT_STUB_COMMON_H
llvm
This class represents lattice values for constants.
Definition:
AllocatorList.h:23
StringRef.h
output
Current output
Definition:
README.txt:1350
Architecture.h
llvm::SmallSet
SmallSet - This maintains a set of unique values, optimizing for the case when the set is small (less...
Definition:
SmallSet.h:134
llvm::raw_ostream
This class implements an extremely fast bulk output stream that can only output to a stream.
Definition:
raw_ostream.h:50
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
llvm::MachO::ObjCConstraintType
ObjCConstraintType
Defines a list of Objective-C constraints.
Definition:
InterfaceFile.h:37
llvm::MachO::ArchitectureSet
Definition:
ArchitectureSet.h:29
llvm::MachO::Architecture
Architecture
Defines the architecture slices that are supported by Text-based Stub files.
Definition:
Architecture.h:27
LLVM_YAML_IS_FLOW_SEQUENCE_VECTOR
#define LLVM_YAML_IS_FLOW_SEQUENCE_VECTOR(type)
LLVM_YAML_STRONG_TYPEDEF
#define LLVM_YAML_STRONG_TYPEDEF(_base, _type)
llvm::MachO::PlatformSet
SmallSet< PlatformKind, 3 > PlatformSet
Definition:
Platform.h:36
UUID
std::pair< llvm::MachO::Target, std::string > UUID
Definition:
TextStubCommon.h:23
YAMLTraits.h
llvm::MachO::PackedVersion
Definition:
PackedVersion.h:25
llvm::StringRef
StringRef - Represent a constant reference to a string, i.e.
Definition:
StringRef.h:57
PackedVersion.h
ArchitectureSet.h
InterfaceFile.h
Generated on Fri Mar 5 2021 22:06:54 for LLVM by
1.8.17