This seems very unlikely.
Possibly, but if units have say a range of 4 and movement 4 (or range 3 movement 5), then my units can be 7 tiles away from yours when I declare war and still be able to attack you.
Should you really pre-emptively attack me just because my naval units are 7 tiles away from yours?