.partial object field names are left unmangled; mangling should be done by the macro instead

This commit is contained in:
Andreas Rumpf 2017-06-05 10:30:24 +02:00
commit 55c244400d
2 changed files with 3 additions and 3 deletions

View file

@ -485,7 +485,7 @@ proc fillPartialObject(c: PContext; n: PNode; typ: PType) =
let y = considerQuotedIdent(n[1])
let obj = x.typ.skipTypes(abstractPtrs)
if obj.kind == tyObject and tfPartial in obj.flags:
let field = newSym(skField, getIdent(y.s & $obj.n.len), obj.sym, n[1].info)
let field = newSym(skField, getIdent(y.s), obj.sym, n[1].info)
field.typ = skipIntLit(typ)
field.position = sonsLen(obj.n)
addSon(obj.n, newSymNode(field))