24 Feb
2009
24 Feb
'09
2:56 a.m.
AMDG Paulino De Assis Fong wrote:
I have two problems that I would need some help. Thanks in advance.
Question 1:
Please consider the regular expression to match US phone number below:
((\(\d{3}\)?)|(\d{3}))([\s-./]?)(\d{3})([\s-./]?)(\d{4})
boost doesn't like it and it will throw an exception for the code below while it seems to be fine in online regex tester and .Net Regex library. I don't know what is imcompatiable with boost regex library. Please advice.
How do you create the regex? std::wstring csRegex(L"((\(\d{3}\)?)|(\d{3}))([\s-./]?)(\d{3})([\s-./]?)(\d{4})") won't work because the \'s are handled by the compiler before they get to the regex library. In Christ, Steven Watanabe