I was hit pretty severely by my parents. It didn't teach me any moral lessons. There's no way it would teach any child decent values, all they'll learn from it is (a) might makes right and (b) don't get caught.
I cannot conceive of and have never heard a convincing argument for seriously hitting a child. They're smaller than you, defenseless, and we're talking about a behavior that you would, hopefully, never do to a stranger, your coworkers, your friends, your spouse, etc. Why do it to your child?
The only real reason that weirdly makes sense, but I completely disagree with, is you think your child is your property, so you get to hit it.
It matters a lot how the parents treat you otherwise. In my case it happened rarely and it came with a scolding to clarify what I did wrong.
Source: was raised like that!