diff options
author | Araq <rumpf_a@web.de> | 2019-04-10 11:04:38 +0200 |
---|---|---|
committer | Araq <rumpf_a@web.de> | 2019-04-10 11:04:38 +0200 |
commit | 28b4db447041207bcc4333c1d6bfa8031e79ebf3 (patch) | |
tree | 574bc0b2e95b7eedc148ba03f3e62025a40b7469 | |
parent | 0518794291f138c1120dc4a039f218598f380eb3 (diff) | |
download | Nim-28b4db447041207bcc4333c1d6bfa8031e79ebf3.tar.gz |
be consistent, strings have destructors for --gc:destructors
-rw-r--r-- | compiler/semtypes.nim | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/compiler/semtypes.nim b/compiler/semtypes.nim index 6e1a666c1..e24597956 100644 --- a/compiler/semtypes.nim +++ b/compiler/semtypes.nim @@ -1811,9 +1811,8 @@ proc processMagicType(c: PContext, m: PSym) = of mString: setMagicType(c.config, m, tyString, szUncomputedSize) rawAddSon(m.typ, getSysType(c.graph, m.info, tyChar)) - when false: - if c.config.selectedGc == gcDestructors: - incl m.typ.flags, tfHasAsgn + if c.config.selectedGc == gcDestructors: + incl m.typ.flags, tfHasAsgn of mCstring: setMagicIntegral(c.config, m, tyCString, c.config.target.ptrSize) rawAddSon(m.typ, getSysType(c.graph, m.info, tyChar)) |