Animating/skinning Leg 180°


So I was having this discussion with a friend about how difficult it is to skin a 3d characters leg if that character has to be able to move it’s leg above it’s head. I remember trying it that one time and I failed missarably; with which i meen that the bottem and upper leg part distort to much to make it feel believable. Now I’m a 3D artist and self thought technical artist so animation isn’t my forté. But it got me thinking, are there any techniekes out there for this specific problem. I’ve been looking around a bit on the internet but I don’t seem to find a topic about it and it got me wondering if there is like some tips or technieks out there I don’t know about.