public PackageSymbol getPackageElement(CharSequence name) {
        String strName = name.toString();
        if (strName.equals(""))
            return syms.unnamedPackage;
        return SourceVersion.isName(strName)
            ? nameToSymbol(strName, PackageSymbol.class)
            : null;
    }