Redmine#4831: check that classes defined by bodies outside our namespace...

... are resolved correctly