From ab38c075f8864a8ddc129e3a4490f11f48d79d38 Mon Sep 17 00:00:00 2001 From: Timothee Cour Date: Wed, 28 Nov 2018 02:46:22 -0500 Subject: add: proc deepCopy*[T](y: T): T (#9740) --- lib/system.nim | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'lib') diff --git a/lib/system.nim b/lib/system.nim index 4414c2107..9111ddd86 100644 --- a/lib/system.nim +++ b/lib/system.nim @@ -4209,6 +4209,10 @@ when hasAlloc and not defined(nimscript) and not defined(JS) and ## for the implementation of ``spawn``. discard + proc deepCopy*[T](y: T): T = + ## Convenience wrapper around `deepCopy` overload. + deepCopy(result, y) + include "system/deepcopy" proc procCall*(x: untyped) {.magic: "ProcCall", compileTime.} = -- cgit 1.4.1-2-gfad0