trying to reorder regexp parsing