Avoid warnings on namespaced types.

The solution is taken from https://github.com/eproxus/meck.