Small fix to previous commit

This commit is contained in:
Bartek Waresiak 2009-07-14 16:05:06 +00:00
parent eb94b62a83
commit 10e7710160

View file

@ -31,7 +31,7 @@ struct token_type {
};
//create the array with list of possible tokens
token_type token_types[] = { { regex("^where\\b"), TOKEN_OPERATOR },
token_type token_types[] = { { regex("^(not\\b|and\\b|or\\b|d(?=[^a-zA-Z])|where\\b)"), TOKEN_OPERATOR },
{ regex("^\\n"), TOKEN_EOL },
{ regex("^([ ]|\\t|\\r|\\f)"), TOKEN_WHITESPACE },
{ regex("^\\("), TOKEN_LPARENS },
@ -46,7 +46,7 @@ token_type token_types[] = { { regex("^where\\b"), TOKEN_OPERATOR },
{ regex("^def\\b"), TOKEN_KEYWORD },
{ regex("^[a-zA-Z_]+"), TOKEN_IDENTIFIER },
{ regex("^\\d+"), TOKEN_INTEGER },
{ regex("^(not\\b|and\\b|or\\b|d(?=[^a-zA-Z])|\\*|\\+|-(?=[^>])|\\^|%|/|<=|>=|<|>|!=|=|\\.\\+|\\.-|\\.\\*|\\./|\\.)"), TOKEN_OPERATOR },
{ regex("^(\\*|\\+|-(?=[^>])|\\^|%|/|<=|>=|<|>|!=|=|\\.\\+|\\.-|\\.\\*|\\./|\\.)"), TOKEN_OPERATOR },
{ regex("^,"), TOKEN_COMMA },
{ regex("^;"), TOKEN_SEMICOLON },
{ regex("^#.*?#"), TOKEN_COMMENT }