CloneSet279


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
54210.995switch_group
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
154160
plugins/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/lookup/WildcardBinding.java
254214
plugins/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/lookup/WildcardBinding.java
Clone Instance
1
Line Count
54
Source Line
160
Source File
plugins/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/lookup/WildcardBinding.java

                        case TypeConstants.CONSTRAINT_EQUAL:  // A == F
                                switch (this.boundKind) {
                                        case Wildcard.UNBOUND: // F={?}
//                                              if (otherType.isWildcard()) {
//                                                      WildcardBinding otherWildcard = (WildcardBinding) otherType;
//                                                      switch(otherWildcard.kind) {
//                                                              case Wildcard.UNBOUND: // A={?} == F={?}  --> 0
//                                                                      break;
//                                                              case Wildcard.EXTENDS: // A={? extends V} == F={?} ---> 0
//                                                                      break;
//                                                              case Wildcard.SUPER: // A={? super V} == F={?} ---> 0
//                                                                      break;
//                                                      }
//                                              } else { // A=V == F={?} ---> 0
//                                              }
                                                break;
                                        case Wildcard.EXTENDS: // F={? extends U}
                                                if (actualType.isWildcard()) {
                                                        WildcardBinding actualWildcard = (WildcardBinding) actualType;
                                                        switch (actualWildcard.boundKind) {
                                                                case Wildcard.UNBOUND: // A={?} == F={? extends U}  --> 0
                                                                        break;
                                                                case Wildcard.EXTENDS: // A={? extends V} == F={? extends U} ---> V == U
                                                                        this.bound.collectSubstitutes(scope, actualWildcard.bound, substitutes, TypeConstants.CONSTRAINT_EQUAL);
                                                                for (int i = 0, length = actualWildcard.otherBounds == null ? 0:  actualWildcard.otherBounds.length; i < length; i++) {
                                                                                this.bound.collectSubstitutes(scope, actualWildcard.otherBounds[i], substitutes, TypeConstants.CONSTRAINT_EQUAL);
                                                                }
                                                                        break;
                                                                case Wildcard.SUPER: // A={? super V} == F={? extends U} ---> 0
                                                                        break;
                                                              }
                                                }
                                                else   { // A=V == F={? extends U} ---> 0
                                                }
                                                break;
                                        case Wildcard.SUPER: // F={? super U}
                                                if (actualType.isWildcard()) {
                                                        WildcardBinding actualWildcard = (WildcardBinding) actualType;
                                                        switch (actualWildcard.boundKind) {
                                                                case Wildcard.UNBOUND: // A={?} == F={? super U}  --> 0
                                                                        break;
                                                                case Wildcard.EXTENDS: // A={? extends V} == F={? super U} ---> 0
                                                                        break;
                                                                case Wildcard.SUPER: // A={? super V} == F={? super U} ---> 0
                                                                        this.bound.collectSubstitutes(scope, actualWildcard.bound, substitutes, TypeConstants.CONSTRAINT_EQUAL);
                                                                for (int i = 0, length = actualWildcard.otherBounds == null ? 0:  actualWildcard.otherBounds.length; i < length; i++) {
                                                                                this.bound.collectSubstitutes(scope, actualWildcard.otherBounds[i], substitutes, TypeConstants.CONSTRAINT_EQUAL);
                                                                }
                                                                break;
                                                              }
                                                }
                                                else   { // A=V == F={? super U} ---> 0
                                                }
                                                break;
                                      }
                                break;


Clone Instance
2
Line Count
54
Source Line
214
Source File
plugins/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/lookup/WildcardBinding.java

                        case TypeConstants.CONSTRAINT_SUPER:  // A >> F
                                switch (this.boundKind) {
                                        case Wildcard.UNBOUND: // F={?}
//                                              if (otherType.isWildcard()) {
//                                                      WildcardBinding otherWildcard = (WildcardBinding) otherType;
//                                                      switch(otherWildcard.kind) {
//                                                              case Wildcard.UNBOUND: // A={?} >> F={?}  --> 0
//                                                                      break;
//                                                              case Wildcard.EXTENDS: // A={? extends V} >> F={?} ---> 0
//                                                                      break;
//                                                              case Wildcard.SUPER: // A={? super V} >> F={?} ---> 0
//                                                                      break;
//                                                      }
//                                              } else { // A=V >> F={?} ---> 0
//                                              }
                                                break;
                                        case Wildcard.EXTENDS: // F={? extends U}
                                                if (actualType.isWildcard()) {
                                                        WildcardBinding actualWildcard = (WildcardBinding) actualType;
                                                        switch (actualWildcard.boundKind) {
                                                                case Wildcard.UNBOUND: // A={?} >> F={? extends U}  --> 0
                                                                        break;
                                                                case Wildcard.EXTENDS: // A={? extends V} >> F={? extends U} ---> V >> U
                                                                        this.bound.collectSubstitutes(scope, actualWildcard.bound, substitutes, TypeConstants.CONSTRAINT_SUPER);
                                                                for (int i = 0, length = actualWildcard.otherBounds == null ? 0:  actualWildcard.otherBounds.length; i < length; i++) {
                                                                                this.bound.collectSubstitutes(scope, actualWildcard.otherBounds[i], substitutes, TypeConstants.CONSTRAINT_SUPER);
                                                                }
                                                                        break;
                                                                case Wildcard.SUPER: // A={? super V} >> F={? extends U} ---> 0
                                                                        break;
                                                              }
                                                }
                                                else   { // A=V == F={? extends U} ---> 0
                                                }
                                                break;
                                        case Wildcard.SUPER: // F={? super U}
                                                if (actualType.isWildcard()) {
                                                        WildcardBinding actualWildcard = (WildcardBinding) actualType;
                                                        switch (actualWildcard.boundKind) {
                                                                case Wildcard.UNBOUND: // A={?} >> F={? super U}  --> 0
                                                                        break;
                                                                case Wildcard.EXTENDS: // A={? extends V} >> F={? super U} ---> 0
                                                                        break;
                                                                case Wildcard.SUPER: // A={? super V} >> F={? super U} ---> V >> U
                                                                        this.bound.collectSubstitutes(scope, actualWildcard.bound, substitutes, TypeConstants.CONSTRAINT_SUPER);
                                                                for (int i = 0, length = actualWildcard.otherBounds == null ? 0:  actualWildcard.otherBounds.length; i < length; i++) {
                                                                                this.bound.collectSubstitutes(scope, actualWildcard.otherBounds[i], substitutes, TypeConstants.CONSTRAINT_SUPER);
                                                                }
                                                                break;
                                                              }
                                                }
                                                else   { // A=V >> F={? super U} ---> 0
                                                }
                                                break;
                                      }
                                break;


Clone AbstractionParameter Count: 1Parameter Bindings

case TypeConstants. [[#variableb8b85200]]: // A == F // A >> F
  switch (this.boundKind) {
    case Wildcard.UNBOUND: // F={?}
      //                                              if (otherType.isWildcard()) {
      //                                                      WildcardBinding otherWildcard = (WildcardBinding) otherType;
      //                                                      switch(otherWildcard.kind) {
      //                                                              case Wildcard.UNBOUND: // A={?} == F={?}  --> 0
      //                                                              case Wildcard.UNBOUND: // A={?} >> F={?}  --> 0
      //                                                                      break;
      //                                                              case Wildcard.EXTENDS: // A={? extends V} == F={?} ---> 0
      //                                                              case Wildcard.EXTENDS: // A={? extends V} >> F={?} ---> 0
      //                                                                      break;
      //                                                              case Wildcard.SUPER: // A={? super V} == F={?} ---> 0
      //                                                              case Wildcard.SUPER: // A={? super V} >> F={?} ---> 0
      //                                                                      break;
      //                                                      }
      //                                              } else { // A=V == F={?} ---> 0
      //                                              } else { // A=V >> F={?} ---> 0
      //                                              }
      break;
    case Wildcard.EXTENDS: // F={? extends U}
      if (actualType.isWildcard()) {
        WildcardBinding actualWildcard = (WildcardBinding) actualType;
        switch (actualWildcard.boundKind) {
          case Wildcard.UNBOUND: // A={?} == F={? extends U}  --> 0 // A={?} >> F={? extends U}  --> 0
            break;
          case Wildcard.EXTENDS: // A={? extends V} == F={? extends U} ---> V == U // A={? extends V} >> F={? extends U} ---> V >> U
            this.bound.collectSubstitutes(scope, actualWildcard.bound, substitutes, TypeConstants. [[#variableb8b85200]]);
            for (int i = 0, length = actualWildcard.otherBounds == null ? 0: actualWildcard.otherBounds.length; i < length; i++) {
              this.bound.collectSubstitutes(scope, actualWildcard.otherBounds[i], substitutes, TypeConstants. [[#variableb8b85200]]);
            }
            break;
          case Wildcard.SUPER: // A={? super V} == F={? extends U} ---> 0 // A={? super V} >> F={? extends U} ---> 0
            break;
        }
      }
      else { // A=V == F={? extends U} ---> 0
      }
      break;
    case Wildcard.SUPER: // F={? super U}
      if (actualType.isWildcard()) {
        WildcardBinding actualWildcard = (WildcardBinding) actualType;
        switch (actualWildcard.boundKind) {
          case Wildcard.UNBOUND: // A={?} == F={? super U}  --> 0 // A={?} >> F={? super U}  --> 0
            break;
          case Wildcard.EXTENDS: // A={? extends V} == F={? super U} ---> 0 // A={? extends V} >> F={? super U} ---> 0
            break;
          case Wildcard.SUPER: // A={? super V} == F={? super U} ---> 0 // A={? super V} >> F={? super U} ---> V >> U
            this.bound.collectSubstitutes(scope, actualWildcard.bound, substitutes, TypeConstants. [[#variableb8b85200]]);
            for (int i = 0, length = actualWildcard.otherBounds == null ? 0: actualWildcard.otherBounds.length; i < length; i++) {
              this.bound.collectSubstitutes(scope, actualWildcard.otherBounds[i], substitutes, TypeConstants. [[#variableb8b85200]]);
            }
            break;
        }
      }
      else { // A=V == F={? super U} ---> 0 // A=V >> F={? super U} ---> 0
      }
      break;
  }
  break;
 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#b8b85200]]
CONSTRAINT_EQUAL 
12[[#b8b85200]]
CONSTRAINT_SUPER