Package com.sun.tools.javac.code

Examples of com.sun.tools.javac.code.Symbol.erasure()


      restype = vsym.erasure(types);
      thrown = List.nil();
      break;
  case MTH:
      acode = DEREFcode;
      argtypes = vsym.erasure(types).getParameterTypes();
      restype = vsym.erasure(types).getReturnType();
      thrown = vsym.type.getThrownTypes();
      break;
  default:
      throw new AssertionError();
View Full Code Here


      thrown = List.nil();
      break;
  case MTH:
      acode = DEREFcode;
      argtypes = vsym.erasure(types).getParameterTypes();
      restype = vsym.erasure(types).getReturnType();
      thrown = vsym.type.getThrownTypes();
      break;
  default:
      throw new AssertionError();
  }
View Full Code Here

    JCExpression makeOwnerThis(DiagnosticPosition pos, Symbol sym, boolean preciseMatch) {
        Symbol c = sym.owner;
        if (preciseMatch ? sym.isMemberOf(currentClass, types)
                         : currentClass.isSubClass(sym.owner, types)) {
            // in this case, `this' works fine
            return make.at(pos).This(c.erasure(types));
        } else {
            // need to go via this$n
            return makeOwnerThisN(pos, sym, preciseMatch);
        }
    }
View Full Code Here

  make.at(pos);
  return
      make.Exec(
    make.Assign(
        make.Select(make.This(lhs.owner.erasure(types)), lhs),
        make.Ident(rhs)).setType(lhs.erasure(types)));
    }

    /** Return tree simulating the assignment <this.this$n = this$n>.
     */
    JCStatement initOuterThis(int pos) {
View Full Code Here

    }

    public void visitApply(JCMethodInvocation tree) {
        tree.meth = translate(tree.meth, null);
        Symbol meth = TreeInfo.symbol(tree.meth);
        Type mt = meth.erasure(types);
        List<Type> argtypes = mt.getParameterTypes();
        if (allowEnums &&
            meth.name==names.init &&
            meth.owner == syms.enumSym)
            argtypes = argtypes.tail.tail;
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.