On 02/04/2021 5:51 PM, mw wrote:
Then how can I construct `t`? to make this assertion true: assert(t == "head-abc-tail"); // failed!
Slice it. string t = text("head-", s[0 .. 3], "-tail"); http://ddili.org/ders/d.en/slices.html
rikki cattermole via Digitalmars-d-learn Thu, 01 Apr 2021 22:05:31 -0700
On 02/04/2021 5:51 PM, mw wrote:
Then how can I construct `t`? to make this assertion true: assert(t == "head-abc-tail"); // failed!
Slice it. string t = text("head-", s[0 .. 3], "-tail"); http://ddili.org/ders/d.en/slices.html