GROOVY-5410: handle method selection for proxy object more carefully
getMetaClass() is passed on to InvocationHandler and $ProvyN is lost:
def dp = Proxy.newProxyInstance(..., invocationHandler)
def mc = dp.getMetaClass()
def c = mc.getTheClass()
"c" refers to class of whatever the handler returned a meta class for