Co-authored-by: cooldome <ariabushenko@bk.ru>
This commit is contained in:
cooldome 2020-05-13 22:57:05 +01:00 • committed by GitHub
commit 5fb40af57e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 19 additions and 5 deletions

View file

@ -942,10 +942,8 @@ proc semAnyRef(c: PContext; n: PNode; kind: TTypeKind; prev: PType): PType =
t.rawAddSonNoPropagationOfTypeFlags result
result = t
else: discard
#if result.kind == tyRef and c.config.selectedGC == gcDestructors:
# result.flags.incl tfHasAsgn
# XXX Something like this is a good idea but it should be done
# in sempass2!
if result.kind == tyRef and c.config.selectedGC in {gcArc, gcOrc}:
result.flags.incl tfHasAsgn
proc findEnforcedStaticType(t: PType): PType =
# This handles types such as `static[T] and Foo`,