\G Match only at pos() (e.g. at the end-of-match position of prior m//g) [snip] The "\G" assertion can be used to chain global matches (using "m//g"), as described in "Regexp Quote-Like Operators" in perlop. It is also useful when writing "lex"-like scanners, when you have several patterns that you want to match against consequent substrings of your string, see the previous reference. The actual location where "\G" will match can also be influenced by using "pos()" as an lvalue: see "pos" in perlfunc. Currently "\G" is only fully supported when anchored to the start of the pattern; while it is permitted to use it elsewhere, as in "/(?<=\G..)./g", some such uses ("/.\G/g", for example) currently cause problems, and it is recommended that you avoid such usage for now.