Below, there are some useful regular expressions for matching C-like primitive data values.
Tag Archive: regular expression
Below, is a simple example for counting words, lines and characters by using a Flex lexer.
In this article I’ll show you a simple PHP function that implements email validation.
The function performs two checks :
It checks both if the email has correct syntax and if the domain of the email exists.
In your lexer when lexical analysis is performed you may want to ignore any multiline C-like comments.
Ignoring multiline comments with start states in compilers with Flex.
In a previous article I have presented a way for ignoring multiline comments with an old fashion way.
In this article I’ll demonstrate a more elegant Flex-like way for ignoring multiline comments.
Continue reading →