It is not ref T, but the ref itself. For example, the following: let x = new Object proc lambda = let y = x # Execute =copy[ref] hook here lambda() # Execute =destroy[ref] hook here # Execute =destroy[Object] hook here Run
I am using Nim 2.0.0. How can I achieve this? Or is there an update planned that would make this possible?