I am just trying to replace if one pattern matches with my string, hence if my string is ABCDH5, it should become ABCDH5m
So the code is written as below
std::string mappedSymbol = boost::regex_replace(tag,from,ruleTo,boost::regex_constants::match_continuous);
here,
tag value is ABCDH5
from value is (ABCD[A-Z][0-9]);
ruleTo value is $1m
But my mappedSymbol is ABCDH5mm.
I am not sure how it is adding extra m to the actual String.
Aucun commentaire:
Enregistrer un commentaire