Thread overview
[Issue 18121] Needleless findSplit* methods
Dec 17, 2022
Iain Buclaw
May 09, 2018
https://issues.dlang.org/show_bug.cgi?id=18121

hsteoh@quickfur.ath.cx changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |hsteoh@quickfur.ath.cx

--
May 09, 2018
https://issues.dlang.org/show_bug.cgi?id=18121

--- Comment #1 from hsteoh@quickfur.ath.cx ---
Found a similar need for needleless overloads of findSplit* today too. The context is that I'm trying to tokenize a string, and if it starts with a digit, say "1234abcd" I'd like to be able to split it into "1234" and "abcd".  So ideally:

------
auto input = "1234abcd";
auto r = input.findSplitBefore!(ch => !isDigit(ch));
assert(r[0] == "1234" && r[1] == "abcd");
------

The current overloads do not allow this, though.

--
December 17, 2022
https://issues.dlang.org/show_bug.cgi?id=18121

Iain Buclaw <ibuclaw@gdcproject.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|P1                          |P4

--
December 01
https://issues.dlang.org/show_bug.cgi?id=18121

--- Comment #2 from dlangBugzillaToGithub <robert.schadek@posteo.de> ---
THIS ISSUE HAS BEEN MOVED TO GITHUB

https://github.com/dlang/phobos/issues/9725

DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB

--