(1) Charitable trusts
For purposes of part II of subchapter F of chapter 1 (other than section 508(a), (b), and (c)) and for purposes of this chapter, a trust which is not exempt from taxation under section 501(a), all of the unexpired interests in which are devoted to one or more of the purposes described in section 170(c)(2)(B), and for which a deduction was allowed under section 170, 545(b)(2), 642(c), 2055, 2106(a)(2), or 2522 (or the corresponding provisions of prior law), shall be treated as an organization described in section 501(c)(3). For purposes of section 509(a)(3)(A), such a trust shall be treated as if organized on the day on which it first becomes subject to this paragraph.
(2) Split-interest trusts
In the case of a trust which is not exempt from tax under section 501(a), not all of the unexpired interests in which are devoted to one or more of the purposes described in section 170(c)(2)(B), and which has amounts in trust for which a deduction was allowed under section 170, 545(b)(2), 642(c), 2055, 2106(a)(2), or 2522, section 507 (relating to termination of private foundation status), section 508(e) (relating to governing instruments) to the extent applicable to a trust described in this paragraph, section 4941 (relating to taxes on self-dealing), section 4943 (relating to taxes on excess business holdings) except as provided in subsection (b)(3), section 4944 (relating to investments which jeopardize charitable purpose) except as provided in subsection (b)(3), and section 4945 (relating to taxes on taxable expenditures) shall apply as if such trust were a private foundation. This paragraph shall not apply with respect to -
(A) any amounts payable under the terms of such trust to income beneficiaries, unless a deduction was allowed under section 170(f)(2)(B), 2055(e)(2)(B), or 2522(c)(2)(B),
(B) any amounts in trust other than amounts for which a deduction was allowed under section 170, 545(b)(2), 642(c), 2055, 2106(a)(2), or 2522, if such other amounts are segregated from amounts for which no deduction was allowable, or
(C) any amounts transferred in trust before May 27, 1969.
(3) Segregated amounts
For purposes of paragraph (2)(B), a trust with respect to which amounts are segregated shall separately account for the various income, deduction, and other items properly attributable to each of such segregated amounts.