I wrote the following function:
std::regex r("");
for (std::sregex_iterator i = words_begin; i != words_end; ++i) {}
It starts looking for regex matches from the beginning of the given string (str) But how may I tell it to exclude everything before specific index?
For example I want it to delete with all of what comes after index number 4 (Not including it).
Note: I am calling this code from another function so I tried something like str + 4 in the string parameter but I got an error that it's not l-value.