We all know these, but from definitions:
Tack, Starboard or Port
A boat is on the tack, starboard or port, corresponding to her windward side.
Leeward and Windward
A boat's leeward side is the side that is or, when she is head to wind, was away from the wind. However, when sailing by the lee or directly downwind, her leeward side is the side on which her mainsail lies. The other side is her windward side. (emphasis added)
One thing I have noticed about the rules is that some things are left undefined. In this case "sailing by the lee." The commonly understood meaning of this term is that is you're not quite DDW, perhaps the wind is a few degrees from your port quarter, and the main is on the same side (so port side). I was sailing along in a race last weekend, going downwind with a spinnaker up at about 150 degrees TWA. Someone suggested that we put the boom on the port side to gain a starboard tack advantage. If I gybed the main I expect it would have stayed.
So, if the main stays where it is, without any preventer or human holding it, is that "sailing by the lee?" Is it "sailing by the lee" if we do hold it? I personally think the rules should address this, but is there an answer in any of the cases?