hibernate/hibernate-validator — pull request #292 by gunnarmorling (2014-01-10 11:38:22+00:00)
Title: HV-645

This unifies the different types of constraint locations which makes things a bit less convoluted. This also removes some fields of the previous distinct location types and thus saves some memory.

One could also think about removing `ConstrainedElement#getLocation()`; `ConstrainedField` and `ConstrainedExecutable` would then need a direct reference to the corresponding member. This would avoid several object allocations during metadata retrieval and even open up the door to get rid of `ConstraintLocation` altogether by pulling its information straight into `MetaConstraint` which then would be the only remaining consumer. IMO this would be a further improvement, I'm not sure about the real-world effect, though. Thus I refrained from doing this change for now.