26 USC 1041 - Transfers of property between spouses or incident to divorce

(a) General rule 
No gain or loss shall be recognized on a transfer of property from an individual to (or in trust for the benefit of)
(1) a spouse, or
(2) a former spouse, but only if the transfer is incident to the divorce.
(b) Transfer treated as gift; transferee has transferor’s basis 
In the case of any transfer of property described in subsection (a)
(1) for purposes of this subtitle, the property shall be treated as acquired by the transferee by gift, and
(2) the basis of the transferee in the property shall be the adjusted basis of the transferor.
(c) Incident to divorce 
For purposes of subsection (a)(2), a transfer of property is incident to the divorce if such transfer
(1) occurs within 1 year after the date on which the marriage ceases, or
(2) is related to the cessation of the marriage.
(d) Special rule where spouse is nonresident alien 
Subsection (a) shall not apply if the spouse (or former spouse) of the individual making the transfer is a nonresident alien.
(e) Transfers in trust where liability exceeds basis 
Subsection (a) shall not apply to the transfer of property in trust to the extent that
(1) the sum of the amount of the liabilities assumed, plus the amount of the liabilities to which the property is subject, exceeds
(2) the total of the adjusted basis of the property transferred.

Proper adjustment shall be made under subsection (b) in the basis of the transferee in such property to take into account gain recognized by reason of the preceding sentence.