foreign corporation to another controlled foreign corporation, such controlled foreign corporation shall be deemed to have paid so much of such other controlled foreign corporation’s foreign income taxes as— (A) are properly attributable to such portion, and (B) have not been deemed to have been paid by a domestic corporation under this section for any prior taxable year. , (2) and by adding after subsection (d) (as added by section 14201) the following new subsections: (e) Foreign income taxes The term foreign income taxes means any income, war profits, or excess profits taxes paid or accrued to any foreign country or possession of the United States. (f) Regulations The Secretary shall prescribe such regulations or other guidance as may be necessary or appropriate to carry out the provisions of this section. . (c) Conforming amendments (1) Section 78 , as amended by section 14201, is amended to read as follows: 78. Gross up for deemed paid foreign tax credit If a domestic corporation chooses to have the benefits of subpart A of part III of subchapter N (relating to foreign tax credit) for any taxable year— (1) an amount equal to the taxes deemed to be paid by such corporation under subsections (a) and (b) of section 960 for such taxable year shall be treated for purposes of this title (other than section 960) as an item of income required to be included in the gross income of such domestic corporation under section 951(a), and (2) an amount equal to the aggregate tested foreign income taxes deemed paid by such corporation under section 960(d) (determined without regard to the phrase 80 percent of in paragraph (1) thereof) shall be treated for purposes of this title (other than section 960) as an addition to the global intangible low-taxed income of such domestic corporation under section 951A(a) for such taxable year. . (2) Paragraph (4) of section 245(a) is amended to read as follows: (4) Post-1986 undistributed earnings The term post-1986 undistributed earnings means the amount of the earnings and profits of