Probably not a good idea! If for some reason the tank leaked or was siphoned dry, it would call for heat and burn itself, and maybe the house. It should turn off if it got too hot, but would still probably self-destruct.
Whenever you turn the water off, it is a good idea to turn off or at least turn it to pilot on the gas WH. Also, if you live where it can freeze, turning it off could allow it to freeze, which would also ruin it...and if it thawed, do major damage to the house.
Taco makes a mechanical WH leak/shutoff detector safety device they call WAGS. This can both shut the water and gas off to the WH if the sensor gets wet. It can be retrofitted, but may be a good thing for when the WH is replaced the next time.