code: private
          boolean isProtectedAccessible(Symbol sym, ClassSymbol c, Type site) {
              Type newSite = site.hasTag(TYPEVAR) ? site.getUpperBound() : site;
              while (c != null &&
                     !(c.isSubClass(sym.owner, types) &&
                       (c.flags() & INTERFACE) == 0 &&
                       // In JLS 2e 6.6.2.1, the subclass restriction applies
                       // only to instance fields and methods -- types are excluded
                       // regardless of whether they are declared 'static' or not.
                       ((sym.flags() & STATIC) != 0 || sym.kind == TYP || newSite.tsym.isSubClass(c, types))))
                  c = c.owner.enclClass();
              return c != null;
          }
docs: Is given protected symbol accessible if it is selected from given site
  and the selection takes place in given class?
  @param sym     The symbol with protected access
  @param c       The class where the access takes place
  @site          The type of the qualifier