Escaping the Tyranny of the GC: std.rcstring, first blood
Andrei Alexandrescu via Digitalmars-d
digitalmars-d at puremagic.com
Sun Sep 14 22:51:15 PDT 2014
On 9/14/14, 9:51 PM, Rikki Cattermole wrote:
>
> static assert("abc".refCounted == "abc");
The idea is we want to write things like:
String s = "abc";
and have it be either refcounted or "classic" depending on the
definition of String. With a user-defined String, you need:
String s = String("abc");
or
auto s = String("abc");
Andrei
More information about the Digitalmars-d
mailing list