in reply to position after global matches?

You can achieve that by using a lookahead or lookbehind assertions. The former will give you the start positions of the matches. The latter the ends (as you've requested).

$_ = 'TATATATATATA'; while (/(?=TATA)/g) { print "Matched 'TATA' at position ", pos, "\n"; };; Matched 'TATA' at position 0 Matched 'TATA' at position 2 Matched 'TATA' at position 4 Matched 'TATA' at position 6 Matched 'TATA' at position 8 $_ = 'TATATATATATA'; while (/(?<=TATA)/g) { print "Matched 'TATA' at position ", pos, "\n"; } Matched 'TATA' at position 4 Matched 'TATA' at position 6 Matched 'TATA' at position 8 Matched 'TATA' at position 10 Matched 'TATA' at position 12

Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.
"Too many [] have been sedated by an oppressive environment of political correctness and risk aversion."