ARC: optimize complete object constructors to use nimNewObjUninit
This commit is contained in:
parent
ab35f07e77
commit
a10cc18247
5 changed files with 40 additions and 12 deletions
|
|
@ -388,3 +388,6 @@ proc semObjConstr(c: PContext, n: PNode, flags: TExprFlags): PNode =
|
|||
# 2) No such field exists in the constructed type
|
||||
localError(c.config, field.info, errUndeclaredFieldX % id.s)
|
||||
return
|
||||
|
||||
if initResult == initFull:
|
||||
incl result.flags, nfAllFieldsSet
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue