Merge exported traits.
Allow exported names to work with namespaces.
Add comment describing why we call setns()

    The reason we need to call this function is a bit subtle and
    annoying.
Don't set the namespace if we don't have one.

    This prevents spurious failures in matching namespaces.