I raise Saint Bernards and I've heard that it's not so much drinking water as it is drinking water with their food.
There are a lot of precautions and a lot of disagreement on what causes bloat, or gastric torsion. They used to say feed the dog from an elevated bowl, now they say the elevated bowl will cause torsion. The reasoning behind not letting the dog drink while it's eating is to prevent the fluid buildup in the stomach, which can lead to solid bits of food passing into the intestines instead of digesting first. Water dilutes digestive acids, so the food in the stomach might not break down sufficiently before it enters the intestines, causing twisting, or bloat.
It's a serious - often fatal condition, so if you have a breed of dog susceptible to bloat, by all means, take precautions to avoid this heartbreaking disorder.