static array with inferred size

Nordlöw per.nordlow at gmail.com
Wed Sep 20 08:33:34 UTC 2017


On Wednesday, 20 September 2017 at 07:38:00 UTC, Jonathan M Davis 
wrote:
> T[n] s(T, size_t n)(auto ref T[n] array) pure nothrow @nogc 
> @safe
> {
>     return array;
> }

What about adding `s` to std.array in the meanwhile? I wonder 
what Walter says about the static array to slice assignment. 
Isn't it memory-safe?


More information about the Digitalmars-d mailing list