adds dfa class and updates expression