diff options
author | flywind <xzsflywind@gmail.com> | 2020-11-13 15:28:22 +0800 |
---|---|---|
committer | flywind <xzsflywind@gmail.com> | 2020-11-13 15:28:22 +0800 |
commit | 0f53b129b78ae480f62a68877778600ba100e96c (patch) | |
tree | e6b6a1f347a284b6f80fb5cdc1303be914e26812 /lib/core | |
parent | 8ec3c141ae28616382a82235b2f4049eaa0ab0d7 (diff) | |
download | Nim-0f53b129b78ae480f62a68877778600ba100e96c.tar.gz |
nil
Diffstat (limited to 'lib/core')
-rw-r--r-- | lib/core/typeinfo.nim | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/core/typeinfo.nim b/lib/core/typeinfo.nim index 2f213956b..00f7c176c 100644 --- a/lib/core/typeinfo.nim +++ b/lib/core/typeinfo.nim @@ -329,6 +329,8 @@ proc setPointer*(x: Any, y: pointer) = assert x.rawType.kind in pointerLike if y != nil: genericAssign(x.value, y, x.rawType) + else: + cast[ppointer](x.value)[] = nil proc fieldsAux(p: pointer, n: ptr TNimNode, ret: var seq[tuple[name: cstring, any: Any]]) = |