For me to understand it, I considered Nim's copy semantics. Find an variable
inside a procedure that gets copied and apply sink to the proc's parameter. If
the argument is not used after the call, then it will be moved to the proc (or
better the memory location it points to), else a copy is performed.
var a = "123"
proc t(a: string) =
let b = a
t(a)
# echo a # this causes a copy
Run
- Re: ELI5: newruntime and arc Yardanico
- Re: ELI5: newruntime and arc ducktape
- Re: ELI5: newruntime and arc leorize
- Re: ELI5: newruntime and arc Araq
- Re: ELI5: newruntime and arc rayman22201
- Re: ELI5: newruntime and arc ducktape
- Re: ELI5: newruntime and arc andrea
- Re: ELI5: newruntime and arc Araq
- Re: ELI5: newruntime and arc rockcavera
- Re: ELI5: newruntime and arc andrea
- Re: ELI5: newruntime and arc b3liever
