diff --git a/lib/core/typeinfo.nim b/lib/core/typeinfo.nim index b1b9bcb273572..9fd8ebf8cef9b 100644 --- a/lib/core/typeinfo.nim +++ b/lib/core/typeinfo.nim @@ -327,10 +327,7 @@ proc setPointer*(x: Any, y: pointer) = ## ``akString``, ``akCString``, ``akProc``, ``akRef``, ``akPtr``, ## ``akPointer``, ``akSequence``. assert x.rawType.kind in pointerLike - when defined(gcDestructors): - genericAssign(x.value, y, x.rawType) - else: - cast[ppointer](x.value)[] = y + genericAssign(x.value, y, x.rawType) proc fieldsAux(p: pointer, n: ptr TNimNode, ret: var seq[tuple[name: cstring, any: Any]]) =