How Does the Regex Library Improve Your Programs?
Brings support for regular expressions to C++Improves the robustness of input validationRegular expressions are very often used in text processing. For example, there are a number of validation tasks that are suitable for regular expressions. Consider an application that requires the input to consist only of numbers. Another program might require a specific format, such as three digits, followed by a character, then two more digits. You could validate ZIP Codes, credit card numbers, Social Security numbers, or just about anything else; and using regular expressions to do the validation is straightforward. Another typical area where regular expressions excel are text substitutionsthat is, replacing some text with other text. Suppose you need to change the spelling of the word colour to color throughout a number of documents. Again, regular expressions provide the best means to do thatincluding remembering to make the changes also for Colour and COLOUR, and for the plural form colours, the verb colourize, and so forth. Yet another use case for regular expressions is in formatting of text.