RFC: Function matchall with overlaps

This closes #8677.
Problem was that the offset was moving one index at a time instead of moving to the start + 1 of the last match. Therefore matching r"GCG" in "GCGCG" matched when offset was 0, 1 and 2 instead of matching with offset 0 and 2.