Skip to content

Conversation

@aardvarkk
Copy link

This is a very basic implementation of a replace-type function. I had the while loop there with the expectation that regex_search would return false if the regex was no longer matched within the string, but it always returned true giving a start_pos() that was past the end of the string. So I just exit from the function if the position of the matched regex is not within the string itself. I'm sure it could be tweaked to be improved, but it worked for my uses so I thought I'd contribute it back if you're interested.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant