Naval gunfire would have played a greater role in the Iraq war, especially the last one; the previous, as well as Vietnam and Korea, had Iowa class battleships available for that role, although there's quite a bit of difference in what this rail gun can do, 23 pound kinetic shell out to 100 miles vs. 16 inch caliber AP and HE shells 100 times as heavy out 1/5 of the distance.
In a future serious war, imagine what one of these, with drone spotting, could do Communist China's PLA naval forces. Note that Taiwan is 110 miles from the mainland's coast, ships with these guns could be in the general vicinity of the island and as long as they had sufficient reconnaissance completely control the surface, reducing an invasion attempt to what's sometimes mocked as a "million-man swim".
They wouldn't have to move as much, which would help with the treat of slow, quiet submarines waiting for you to come into range.
For the former, you're evidently not familiar with the role naval gunfire support played; if not those instances, e.g. I remember the Royal Australian Navy(RAN) Anzac using its 5 inch gun in support of the combined US and British Royal Marine push into the Al-Faw Peninsula right flank, read up on e.g. the WWII invasion of Sicily or D-Day, when Omaha beach had two old US battleships dedicated to it (would have hated to be a German on the other side when e.g. the Texas used it's 10 14 inch guns to "clear" a beach exit).
For the latter, the misattributed Trotsky quote "You may not be interested in war, but war is interested in you." applies. As does the principle of deterrence.
In a future serious war, imagine what one of these, with drone spotting, could do Communist China's PLA naval forces. Note that Taiwan is 110 miles from the mainland's coast, ships with these guns could be in the general vicinity of the island and as long as they had sufficient reconnaissance completely control the surface, reducing an invasion attempt to what's sometimes mocked as a "million-man swim".
They wouldn't have to move as much, which would help with the treat of slow, quiet submarines waiting for you to come into range.