added lookahead token argument to reduce functions