Package org.eclipse.jdt.internal.compiler.lookup

Examples of org.eclipse.jdt.internal.compiler.lookup.ReferenceBinding.superclass()


        interfacesToVisit = new ReferenceBinding[5][];
      if (++lastPosition == interfacesToVisit.length)
        System.arraycopy(interfacesToVisit, 0, interfacesToVisit = new ReferenceBinding[lastPosition * 2][], 0, lastPosition);
      interfacesToVisit[lastPosition] = itsInterfaces;
    }
    if ((currentType = currentType.superclass()) == null)
      break;

    if ((field = currentType.getField(fieldName, true /*resolve*/)) != null) {
      keepLooking = false;
      if (canBeSeenByForCodeSnippet(field, receiverType, invocationSite, this)) {
View Full Code Here


        @Override
        public boolean isSubclassOf(@NonNull String name, boolean strict) {
            if (mBinding instanceof ReferenceBinding) {
                ReferenceBinding cls = (ReferenceBinding) mBinding;
                if (strict) {
                    cls = cls.superclass();
                }
                for (; cls != null; cls = cls.superclass()) {
                    if (sameChars(name, cls.readableName())) {
                        return true;
                    }
View Full Code Here

            if (mBinding instanceof ReferenceBinding) {
                ReferenceBinding cls = (ReferenceBinding) mBinding;
                if (strict) {
                    cls = cls.superclass();
                }
                for (; cls != null; cls = cls.superclass()) {
                    if (sameChars(name, cls.readableName())) {
                        return true;
                    }
                }
            }
View Full Code Here

    ReferenceBinding enclosingReceiverType = scope.enclosingReceiverType();
    if (enclosingReceiverType.id == T_JavaLangObject) {
      scope.problemReporter().cannotUseSuperInJavaLangObject(this);
      return null;
    }
    return this.resolvedType = enclosingReceiverType.superclass();
  }

  public void traverse(ASTVisitor visitor, BlockScope blockScope) {
    visitor.visit(this, blockScope);
    visitor.endVisit(this, blockScope);
View Full Code Here

      }
      methodScope.isConstructorCall = true;
      ReferenceBinding receiverType = scope.enclosingReceiverType();
      boolean rcvHasError = false;
      if (this.accessMode != ExplicitConstructorCall.This) {
        receiverType = receiverType.superclass();
        TypeReference superclassRef = scope.referenceType().superclass;
        if (superclassRef != null && superclassRef.resolvedType != null && !superclassRef.resolvedType.isValidBinding()) {
          rcvHasError = true;
        }
      }
View Full Code Here

    // https://bugs.eclipse.org/bugs/show_bug.cgi?id=245007 avoid secondary errors in case of
    // missing super type for anonymous classes ...
    ReferenceBinding declaringClass = this.binding.declaringClass;
    boolean avoidSecondary = declaringClass != null &&
                 declaringClass.isAnonymousType() &&
                 declaringClass.superclass() instanceof MissingTypeBinding;
    if (!avoidSecondary)
      scope.problemReporter().invalidMethod(this, this.binding);
    MethodBinding closestMatch = ((ProblemMethodBinding)this.binding).closestMatch;
    switch (this.binding.problemId()) {
      case ProblemReasons.Ambiguous :
View Full Code Here

    // https://bugs.eclipse.org/bugs/show_bug.cgi?id=245007 avoid secondary errors in case of
    // missing super type for anonymous classes ...
    ReferenceBinding declaringClass = fieldBinding.declaringClass;
    boolean avoidSecondary = declaringClass != null &&
                 declaringClass.isAnonymousType() &&
                 declaringClass.superclass() instanceof MissingTypeBinding;
    if (!avoidSecondary) {
      scope.problemReporter().invalidField(this, this.actualReceiverType);
    }
    if (fieldBinding instanceof ProblemFieldBinding) {
      ProblemFieldBinding problemFieldBinding = (ProblemFieldBinding) fieldBinding;
View Full Code Here

        @Override
        public boolean isSubclassOf(@NonNull String name, boolean strict) {
            if (mBinding instanceof ReferenceBinding) {
                ReferenceBinding cls = (ReferenceBinding) mBinding;
                if (strict) {
                    cls = cls.superclass();
                }
                for (; cls != null; cls = cls.superclass()) {
                    if (sameChars(name, cls.readableName())) {
                        return true;
                    }
View Full Code Here

            if (mBinding instanceof ReferenceBinding) {
                ReferenceBinding cls = (ReferenceBinding) mBinding;
                if (strict) {
                    cls = cls.superclass();
                }
                for (; cls != null; cls = cls.superclass()) {
                    if (sameChars(name, cls.readableName())) {
                        return true;
                    }
                }
            }
View Full Code Here

        @Override
        public boolean isSubclassOf(@NonNull String name, boolean strict) {
            if (mBinding instanceof ReferenceBinding) {
                ReferenceBinding cls = (ReferenceBinding) mBinding;
                if (strict) {
                    cls = cls.superclass();
                }
                for (; cls != null; cls = cls.superclass()) {
                    if (sameChars(name, cls.readableName())) {
                        return true;
                    }
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.