Hibernate 6.2 will introduce a check for this type of problem and an appropriate error message, as per https://hibernate.atlassian.net/browse/HHH-16313 .
Closing the issue.