diff options
Diffstat (limited to 'source/slang/mangle.cpp')
| -rw-r--r-- | source/slang/mangle.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/source/slang/mangle.cpp b/source/slang/mangle.cpp index 070c2b172..1a412d041 100644 --- a/source/slang/mangle.cpp +++ b/source/slang/mangle.cpp @@ -408,6 +408,22 @@ namespace Slang } String getMangledNameForConformanceWitness( + DeclRef<Decl> sub, + Type* sup) + { + // The mangled form for a witness that `sub` + // conforms to `sup` will be named: + // + // {Conforms(sub,sup)} => _SW{sub}{sup} + // + ManglingContext context; + emitRaw(&context, "_SW"); + emitQualifiedName(&context, sub); + emitType(&context, sup); + return context.sb.ProduceString(); + } + + String getMangledNameForConformanceWitness( Type* sub, Type* sup) { |
