code: public static boolean isSelfCall(JCTree tree) {
          Name name = calledMethodName(tree);
          if (name != null) {
              Names names = name.table.names;
              return name==names._this || name==names._super;
          } else {
              return false;
          }
      }
docs: Is this a call to this or super?