splitting lex functions