In general
Except as provided in paragraph (2), if an individual has filed a separate return for a taxable year for which a joint return could have been made by him and his spouse under subsection (a) and the time prescribed by law for filing the return for such taxable year has expired, such individual and his spouse may nevertheless make a joint return for such taxable year. A joint return filed by the husband and wife under this subsection shall constitute the return of the husband and wife for such taxable year, and all payments, credits, refunds, or other repayments made or allowed with respect to the separate return of either spouse for such taxable year shall be taken into account in determining the extent to which the tax based upon the joint return has been paid. If a joint return is made under this subsection, any election (other than the election to file a separate return) made by either spouse in his separate return for such taxable year with respect to the treatment of any income, deduction, or credit of such spouse shall not be changed in the making of the joint return where such election would have been irrevocable if the joint return had not been made. If a joint return is made under this subsection after the death of either spouse, such return with respect to the decedent can be made only by his executor or administrator.