needles
in haystack. If no character of needles is found or stopIdx is 0, then -1 is returned. If the parameters are not valid UTF, the result will still be in the range [-1 .. stopIdx], but will not be reliable otherwise.
ptrdiff_t lastIndexOfAny(Char, Char2)(const(Char)[] haystack,
const(Char2)[] needles, in CaseSensitive cs = Yes.caseSensitive) if (isSomeChar!Char && isSomeChar!Char2) @safe pureSearches haystack for the last occurrence of any of the characters in needles.
haystack | string to search needles in |
needles | characters to search for in haystack |
stopIdx | index in haystack to stop searching at (exclusive); defaults to haystack.length |
cs | specifies whether comparisons are case-sensitive (Yes.caseSensitive) or not (No.caseSensitive) |
needles
in haystack. If no character of needles is found or stopIdx is 0, then -1 is returned. If the parameters are not valid UTF, the result will still be in the range [-1 .. stopIdx], but will not be reliable otherwise.
ptrdiff_t lastIndexOfAny(Char, Char2)(const(Char)[] haystack,
const(Char2)[] needles, in size_t stopIdx,
in CaseSensitive cs = Yes.caseSensitive) if (isSomeChar!Char && isSomeChar!Char2) @safe pureDitto