use two underscores for easy demangling [backport:1.6] (#19028)

This commit is contained in:
Andreas Rumpf 2021-10-21 16:53:15 +02:00 • committed by GitHub
commit 1a45da9150
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -39,7 +39,7 @@ proc mangleName(m: BModule; s: PSym): Rope =
result = s.loc.r result = s.loc.r
if result == nil: if result == nil:
result = s.name.s.mangle.rope result = s.name.s.mangle.rope
result.add "_" result.add "__"
result.add m.g.graph.ifaces[s.itemId.module].uniqueName result.add m.g.graph.ifaces[s.itemId.module].uniqueName
result.add "_" result.add "_"
result.add rope s.itemId.item result.add rope s.itemId.item