fixes #5142
This commit is contained in:
parent
77d5d0cdfe
commit
93fb8b67b9
2 changed files with 15 additions and 5 deletions
|
|
@ -116,16 +116,18 @@ proc mangleName(m: BModule; s: PSym): Rope =
|
|||
add(result, m.idOrSig(s))
|
||||
s.loc.r = result
|
||||
|
||||
proc typeName(typ: PType): Rope =
|
||||
result = if typ.sym != nil and typ.kind in {tyObject, tyEnum}:
|
||||
typ.sym.name.s.mangle.rope
|
||||
else:
|
||||
~"TY"
|
||||
|
||||
const
|
||||
irrelevantForBackend = {tyGenericBody, tyGenericInst, tyGenericInvocation,
|
||||
tyDistinct, tyRange, tyStatic, tyAlias}
|
||||
|
||||
proc typeName(typ: PType): Rope =
|
||||
let typ = typ.skipTypes(irrelevantForBackend)
|
||||
result = if typ.sym != nil and typ.kind in {tyObject, tyEnum}:
|
||||
typ.sym.name.s.mangle.rope
|
||||
else:
|
||||
~"TY"
|
||||
|
||||
proc getTypeName(m: BModule; typ: PType; sig: SigHash): Rope =
|
||||
var t = typ
|
||||
while true:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue