fixed the cpp code for pb9 usage + upgraded the pb9 code of PbRegexCoach to the new features