Add type proxy workaround for lookupVariable and lookupTypeVariable functions