'Return the package (a CIX <scope ilk="class"> element) for
the given package name. If the package definition cannot be
found, this returns None.'

def pkg_from_pkg_name(self, pkg_name):

    if (pkg_name in self._mod_from_pkg_name):
        mod = self._mod_from_pkg_name[pkg_name]
        if (mod is not None):
            return mod.names.get(pkg_name)
    for (mod, pkg_names) in self._generator:
        if (mod is None):
            continue
        if (pkg_name in pkg_names):
            return mod.names.get(pkg_name)
    return None
