his spouse at all times during the taxable year. . (c) Hospital Insurance Trust Fund held harmless Section 121(e)(1) of the Social Security Amendments of 1986 ( 42 U.S.C. 401 note) is amended by adding at the end the following new subparagraph: (C) The amounts appropriated to the hospital insurance trust fund by subparagraph (B) shall be determined, and transferred from the general fund, at such times and in such manner so as to replicate, to the extent possible, the appropriations and transfers which would have occurred with respect to such trust fund had subsections (a) and (b) of section 104 of the Social Security 2100 Act not been enacted. . (d) Effective date The amendments made by this section shall apply to taxable years beginning after December 31, 2017. 105. Holding SSI, Medicaid, and CHIP beneficiaries harmless For purposes of determining the income of an individual to establish eligibility for, and the amount of, benefits payable under title XVI of the Social Security Act, eligibility for medical assistance under the State plan under title XIX (or a waiver of such plan), or eligibility for child health assistance under the State child health plan under title XXI (or a waiver of the plan), the amount of any benefit to which the individual is entitled under title II of such Act shall be deemed not to exceed the amount of the benefit that would be determined for such individual under such title as in effect on the day before the date of the enactment of this Act. II Strengthening the Trust Fund 201. Determination of wages and self-employment income above contribution and benefit base after 2017 (a) Determination of wages above contribution and benefit base after 2017 (1) Amendments to the Internal Revenue Code (A) In general Paragraph (1) of section 3121(a) of the Internal Revenue Code of 1986 is amended by inserting after such calendar year. the following: The preceding sentence shall apply only to calendar years for which the contribution and benefit base (as so determined) is less than $400,000, and,