From 856005804293003fabb483d99c6ffdb29dd14235 Mon Sep 17 00:00:00 2001 From: Andreas Rumpf Date: Sun, 2 Jun 2019 08:17:37 +0200 Subject: [PATCH] Updated Destructors (rest) --- Destructors.rest | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Destructors.rest b/Destructors.rest index ae384f8..f399153 100644 --- a/Destructors.rest +++ b/Destructors.rest @@ -1,3 +1,5 @@ +**Note**: This document is succeeded by https://github.com/nim-lang/Nim/wiki/Destructors,-2nd-edition + This page is a follow-up of https://nim-lang.org/araq/destructors.html and further outlines of where Nim is heading in the future. (Did I hear anyone say "Nim v2"?) Nim's strings and sequences should become "GC-free" implementations and are exemplary for how Nim's core should work. Strings and sequences are value-based that means ``=`` performs a copy (conceptually). In practice many copies can be optimized away (see my blog post). The "optimized" copy is called a "move" and is supported via the type bound operator ``=sink``.