I am using boost 1.54 library in my program. My task is to expand some patterns in a string.
One such instance is if a closing brace }
is found in the string replace it with >
I had written the following regex in my code.
boost::wregex rightbrace(L"\}"); // replace this by >
strText = boost::regex_replace(strText, rightbrace, L">");
My code is compiling fine. But my program crashes when it encounters the first statement it crashes with the following exception
Unhandled exception at 0x7599c41f in Compress.exe: Microsoft C++ exception: boost::exception_detail::clone_impl > @ 0x0018fa54
Since }
is a special symbol I have escaped it with \
symbol.
Can anyone tell me what is the issue here?