I don’t know if it’s standard Islam. The Spanish fortress in Manila has a chamber that is below water level during high tide. They used to lock prisoners in it and watch the water rise.
But the Spaniards of the 1500s could have learned that from the Moors.
In a movement founded by a thief, murderer and pedophile, I regard such actions as SOP.