mirror of
https://github.com/nim-lang/Nim.git
synced 2026-04-18 21:40:32 +00:00
add: proc deepCopy*[T](y: T): T (#9740)
This commit is contained in:
committed by
Andreas Rumpf
parent
8ff18c0fb9
commit
ab38c075f8
@@ -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.} =
|
||||
|
||||
Reference in New Issue
Block a user