This is not entirely true- a longer barrel means that the expanding gasses in a firearm spend more time pushing the bullet, increasing the velocity, as shown in this data I just grabbed from a quick google search:...While the size of a chemical slugthrower really only affects stability and accuracy (a .50 caliber bullet will, in theory, do the same amount of damage whether fired from a cannon or a handgun...)
"The 13.5-inch length could propel a 168 grain Hornady TAP round at an average velocity of 2390 fps (728.472 m/s), which is hardly slow. That is only a decrease of around 315 fps (96.012m/s) from the 26 inch length..."
The round is a 168 grain .308, or .0108862169 kg. Given KE=1/2mv^2, the difference in the kinetic energy between rounds was roughly 50.17622 kJ. Admittedly, this is not much compared to the total KE of the 13.5 inch barrel (roughly 2888.5 kJ), but the change in velocity does affect the amount of lead required and any increase in power is welcome, even if it is small.
Other than that, thanks for the explanation on the particle beam weapons .