Sometimes rust resistance can be improved by a "passivated finish," which is a surface treatment for stainless. It consists of dipping the part in an acid solution followed by washing with deionized water. This removes embedded tool steel particles, heat treat scale, etc. and leaves the surface with a rust resisting "film." If you could disassemble the gun (to eliminate trapped fluid) there are jobbers who could do it. There are no dimensional changes from passivation. The 300 series (also 18-8) stainless steels such as 301, 303, 302, 304, 316, 321, etc. are good in corrosion resistance but can be subject to attack by crevice corrosion. They CANNOT be heat treated but can be work hardened, and can be bought in quarter hard, half hard, and full hard condition. 304L and 316L steels have the "L" added for "Low Carbon," and they are much more resistant to attack (316L is superior for marine applications). Examples of heat treatable stainless steels are 17-4PH, 15-5PH, and PH13-8Mo. The "PH" stands for "Precipitation Hardening" which is how these steels are heat treated, an elevated temperature soak followed by air cooling. PH13-8Mo is about the highest strength SS, it can be treated to H900 temper but is notch sensitive and the higher strengths are more susceptible to stress corrosion cracking. They WILL rust, especially from environmental conditions if left outdoors. They are best machined in the finally desired heat treated condition, then passivated and placed in service. 400 series are extremely hard but brittle and find use as ball bearings (440) and some knife blades. 400 series is also very magnetic, the PH series less so. Treatments to harden the surface of stainless steels are limited (can't carburize, for example) but you can use TiN (Titanium Nitride) for high wear applications. The only truly corrosion resistant, heat treatable material is a titanium alloy, such as 6Al-4V (6% Aluminum, 4% Vanadium). If you have cast stainless steel expect a witches' brew of inclusions and flow additives, the inclusions might rust and cause pitting. You might try a hard chrome finish or one of the proprietary coatings, be advised there will be some slight dimensional (additive) changes.
------------------
"Our most pressing problems...are at their core moral, not material, problems." Richard Nixon
"We should not substitute the state for the parents or the family." Lee Kwan Yew