function to get names of namespaces descended from