File tree Expand file tree Collapse file tree 2 files changed +14
-0
lines changed Expand file tree Collapse file tree 2 files changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -38,3 +38,12 @@ std::optional<std::string> SwiftMangler::mangleType(const swift::ModuleType& typ
38
38
}
39
39
return key;
40
40
}
41
+
42
+ #define TYPE (TYPE_ID, PARENT_TYPE )
43
+ #define BUILTIN_TYPE (TYPE_ID, PARENT_TYPE ) \
44
+ std::optional<std::string> SwiftMangler::mangleType (const swift::TYPE_ID##Type& type) { \
45
+ llvm::SmallString<32 > buffer; \
46
+ type.getTypeName (buffer); \
47
+ return buffer.str ().str (); \
48
+ }
49
+ #include < swift/AST/TypeNodes.def>
Original file line number Diff line number Diff line change @@ -15,6 +15,11 @@ class SwiftMangler {
15
15
16
16
std::optional<std::string> mangleType (const swift::ModuleType& type);
17
17
18
+ #define TYPE (TYPE_ID, PARENT_TYPE )
19
+ #define BUILTIN_TYPE (TYPE_ID, PARENT_TYPE ) \
20
+ std::optional<std::string> mangleType (const swift::TYPE_ID##Type& type);
21
+ #include < swift/AST/TypeNodes.def>
22
+
18
23
private:
19
24
swift::Mangle::ASTMangler mangler;
20
25
};
You can’t perform that action at this time.
0 commit comments