Lazy std.algorithm.replace()
    Nordlöw via Digitalmars-d-learn 
    digitalmars-d-learn at puremagic.com
       
    Mon Nov  2 12:34:18 PST 2015
    
    
  
On Monday, 2 November 2015 at 20:25:44 UTC, Adam D. Ruppe wrote:
> On Sunday, 1 November 2015 at 14:26:21 UTC, Nordlöw wrote:
>> Is there a reason why Phobos doesn't contain a lazy range 
>> variant of std.string.replace?
>
> Would something like map work with the predicate being 
> if(matches_needle) return replacement; else return original; ?
I'm already using `map` in the simple overloads (Range haystack, 
ElementType needle) mentioned in my previous post.
    
    
More information about the Digitalmars-d-learn
mailing list