If any portion of an accumulation distribution for any taxable year is deemed under subsection (a) to be an amount within the meaning of paragraph (2) of section
661
(a) distributed on the last day of any preceding taxable year, and such portion of such distribution is not less than the undistributed net income for such preceding taxable year, the trust shall be deemed to have distributed on the last day of such preceding taxable year an additional amount within the meaning of paragraph (2) of section
661
(a). Such additional amount shall be equal to the taxes (other than the tax imposed by section
55) imposed on the trust for such preceding taxable year attributable to the undistributed net income. For purposes of this subsection, the undistributed net income and the taxes imposed on the trust for such preceding taxable year attributable to such undistributed net income shall be computed without regard to such accumulation distribution and without regard to any accumulation distribution determined for any succeeding taxable year.