Maybe modern computers fully overcome my thinking on the question and can manage both as a team.
Keep in mind that the missiles will be homing or guided missiles. The sights for the gun part of the system don’t really matter as the missiles really only need to be pointed in the general direction of the target and launched. The mount they’re on will have only minimal involvement beyond launch.
FYI, the Russians have been very successful with recent gun/missile combo systems. The Russian Tunguska (SA-19 Grison) self-propelled AA gun/missile system has a pretty good combat record.