ir: Add buildAssign utility function.
semantic: Gather constructors.