Thank you very much for your additions.
I am still new to D so I am glad to see solutions from
experienced D programmers.
Hello,
I would like to create a D function that returns a slice of a
string.
This slice shall be a reference to a part of the string argument.
Is this generally possible in D?
This is the function:
auto ref betweenTwoStrings(T)(inout T src, string start, string
end) {
long a =
On Wednesday, 29 October 2014 at 19:54:45 UTC, bearophile wrote:
advibm:
I would like to have something like that:
char[] buf; // already filled array
char[] partOfBuf = betweenTwoStrings(buf, START, END);
partOfBuf[0] = 'a'; // THIS should also change the 'buf'
variable
assert(buf[0] ==