(a) Except as provided in subdivision (b), any person who personally uses a firearm in the commission of a felony or attempted felony shall be punished by an additional and consecutive term of imprisonment in the state prison for 3, 4, or 10 years, unless use of a firearm is an element of that offense.
(b) Notwithstanding subdivision (a), any person who personally uses an assault weapon, as specified in Section 30510 or 30515, or a machinegun, as defined in Section 16880, in the commission of a felony or attempted felony, shall be punished by an additional and consecutive term of imprisonment in the state prison for 5, 6, or 10 years.
(c) The court may, in the interest of justice pursuant to Section 1385 and at the time of sentencing, strike or dismiss an enhancement otherwise required to be imposed by this section. The authority provided by this subdivision applies to any resentencing that may occur pursuant to any other law.
(d) Notwithstanding the limitation in subdivision (a) relating to being an element of the offense, the additional term provided by this section shall be imposed for any violation of Section 245 if a firearm is used, or for murder if the killing is perpetrated by means of shooting a firearm from a motor vehicle, intentionally at another person outside of the vehicle with the intent to inflict great bodily injury or death.
(e) When a person is found to have personally used a firearm, an assault weapon, a machinegun, or a .50 BMG rifle, in the commission of a felony or attempted felony as provided in this section and the firearm, assault weapon, machinegun, or a .50 BMG rifle, is owned by that person, the court shall order that the firearm be deemed a nuisance and disposed of in the manner provided in Sections 18000 and 18005.
(f) For purposes of imposing an enhancement under Section 1170.1, the enhancements under this section shall count as one single enhancement.
(Amended by Stats. 2017, Ch. 682, Sec. 1. (SB 620) Effective January 1, 2018.)