The point is not to make it work. The point is why compiler allows it and maybe some more meaningful exception should be thrown?