regex adverb :overlap

Documentation for regex adverb :overlap, assembled from the following types:

language documentation Regexes

From Regexes

(Regexes) regex adverb :overlap

To get several matches, including overlapping matches, but only one (the longest) from each starting position, specify the :overlap (short :ov) adverb:

given 'abracadabra' {
    for m:overlap/ a .* a / -> $match {
        say ' ' x $match.from~$match;
    }
}

produces

abracadabra
   acadabra
     adabra
       abra