#3438 - Adding support for non-static top-level classes in check constr...

...uctors

Should be backported to release-2.2