Examples of findSuperTypeOriginatingFrom()


Examples of org.eclipse.jdt.internal.compiler.lookup.ParameterizedTypeBinding.findSuperTypeOriginatingFrom()

                  // need to clone for each iteration to avoid env paramtype cache interference
                  System.arraycopy(paramCastType.arguments, 0, alternateArguments = new TypeBinding[length], 0, length);
                  alternateArguments[i] = scope.getJavaLangObject();
                  LookupEnvironment environment = scope.environment();
                  ParameterizedTypeBinding alternateCastType = environment.createParameterizedType((ReferenceBinding)castType.erasure(), alternateArguments, castType.enclosingType());
                  if (alternateCastType.findSuperTypeOriginatingFrom(expressionType) == match) {
                    this.bits |= ASTNode.UnsafeCast;
                    break;
                  }
                }
              }
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.lookup.ParameterizedTypeBinding.findSuperTypeOriginatingFrom()

                  // need to clone for each iteration to avoid env paramtype cache interference
                  System.arraycopy(paramCastType.arguments, 0, alternateArguments = new TypeBinding[length], 0, length);
                  alternateArguments[i] = scope.getJavaLangObject();
                  LookupEnvironment environment = scope.environment();
                  ParameterizedTypeBinding alternateCastType = environment.createParameterizedType((ReferenceBinding)castType.erasure(), alternateArguments, castType.enclosingType());
                  if (alternateCastType.findSuperTypeOriginatingFrom(expressionType) == match) {
                    this.bits |= ASTNode.UnsafeCast;
                    break;
                  }
                }
              }
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.lookup.ParameterizedTypeBinding.findSuperTypeOriginatingFrom()

                  // need to clone for each iteration to avoid env paramtype cache interference
                  System.arraycopy(paramCastType.arguments, 0, alternateArguments = new TypeBinding[length], 0, length);
                  alternateArguments[i] = scope.getJavaLangObject();
                  LookupEnvironment environment = scope.environment();
                  ParameterizedTypeBinding alternateCastType = environment.createParameterizedType((ReferenceBinding)castType.erasure(), alternateArguments, castType.enclosingType());
                  if (alternateCastType.findSuperTypeOriginatingFrom(expressionType) == match) {
                    this.bits |= ASTNode.UnsafeCast;
                    break;
                  }
                }
              }
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.lookup.ParameterizedTypeBinding.findSuperTypeOriginatingFrom()

                  // need to clone for each iteration to avoid env paramtype cache interference
                  System.arraycopy(paramCastType.arguments, 0, alternateArguments = new TypeBinding[length], 0, length);
                  alternateArguments[i] = scope.getJavaLangObject();
                  LookupEnvironment environment = scope.environment();
                  ParameterizedTypeBinding alternateCastType = environment.createParameterizedType((ReferenceBinding)castType.erasure(), alternateArguments, castType.enclosingType());
                  if (TypeBinding.equalsEquals(alternateCastType.findSuperTypeOriginatingFrom(expressionType), match)) {
                    this.bits |= ASTNode.UnsafeCast;
                    break;
                  }
                }
              }
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.lookup.ParameterizedTypeBinding.findSuperTypeOriginatingFrom()

                  // need to clone for each iteration to avoid env paramtype cache interference
                  System.arraycopy(paramCastType.arguments, 0, alternateArguments = new TypeBinding[length], 0, length);
                  alternateArguments[i] = scope.getJavaLangObject();
                  LookupEnvironment environment = scope.environment();
                  ParameterizedTypeBinding alternateCastType = environment.createParameterizedType((ReferenceBinding)castType.erasure(), alternateArguments, castType.enclosingType());
                  if (alternateCastType.findSuperTypeOriginatingFrom(expressionType) == match) {
                    this.bits |= ASTNode.UnsafeCast;
                    break;
                  }
                }
              }
View Full Code Here

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

          default :
            if (castType.isInterface()) {
              // ( INTERFACE ) INTERFACE
              ReferenceBinding interfaceType = (ReferenceBinding) expressionType;
              match = interfaceType.findSuperTypeOriginatingFrom(castType);
              if (match != null) {
                return checkUnsafeCast(scope, castType, interfaceType, match, false);
              }
              tagAsNeedCheckCast();
              match = castType.findSuperTypeOriginatingFrom(interfaceType);
View Full Code Here

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

          default :
            if (castType.isInterface()) {
              // ( INTERFACE ) CLASS
              ReferenceBinding refExprType = (ReferenceBinding) expressionType;
              match = refExprType.findSuperTypeOriginatingFrom(castType);
              if (match != null) {
                return checkUnsafeCast(scope, castType, expressionType, match, false);
              }
              // unless final a subclass may implement the interface ==> no check at compile time
              if (refExprType.isFinal()) {
View Full Code Here

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

      && field.isPrivate()
      && field.isFinal()
      && TypeBinding.LONG == field.type) {
    ReferenceBinding referenceBinding = field.declaringClass;
    if (referenceBinding != null) {
      if (referenceBinding.findSuperTypeOriginatingFrom(TypeIds.T_JavaIoSerializable, false /*Serializable is not a class*/) != null) {
        return; // do not report field hiding for serialVersionUID field for class that implements Serializable
      }
    }
  }
  if (CharOperation.equals(TypeConstants.SERIALPERSISTENTFIELDS, field.name)
View Full Code Here

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

      && field.isFinal()
      && field.type.dimensions() == 1
      && CharOperation.equals(TypeConstants.CharArray_JAVA_IO_OBJECTSTREAMFIELD, field.type.leafComponentType().readableName())) {
    ReferenceBinding referenceBinding = field.declaringClass;
    if (referenceBinding != null) {
      if (referenceBinding.findSuperTypeOriginatingFrom(TypeIds.T_JavaIoSerializable, false /*Serializable is not a class*/) != null) {
        return; // do not report field hiding for serialPersistenFields field for class that implements Serializable
      }
    }
  }
  boolean isLocal = hiddenVariable instanceof LocalVariableBinding;
View Full Code Here

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

      && field.isStatic()
      && field.isFinal()
      && TypeBinding.LONG == field.type) {
    ReferenceBinding referenceBinding = field.declaringClass;
    if (referenceBinding != null) {
      if (referenceBinding.findSuperTypeOriginatingFrom(TypeIds.T_JavaIoSerializable, false /*Serializable is not a class*/) != null) {
        return; // do not report unused serialVersionUID field for class that implements Serializable
      }
    }
  }
  if (CharOperation.equals(TypeConstants.SERIALPERSISTENTFIELDS, field.name)
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.