Alter tests a bit
This commit is contained in:
parent
9eb0dd1cf5
commit
4a18a81b33
@ -4,7 +4,7 @@ public class TestContraVariant {
|
||||
var y3 = y2.snd();
|
||||
var z;
|
||||
y3 = z;
|
||||
return new Pair(x,z);
|
||||
return new Pair<>(x, z);
|
||||
}
|
||||
|
||||
m(x, y) {
|
||||
@ -12,6 +12,27 @@ public class TestContraVariant {
|
||||
var x3 = x2.fst();
|
||||
var z;
|
||||
x3 = z;
|
||||
return new Pair(z, y);
|
||||
return new Pair<>(z, y);
|
||||
}
|
||||
}
|
||||
|
||||
class Pair<T, U> {
|
||||
public T x;
|
||||
public U y;
|
||||
|
||||
public Pair() {
|
||||
}
|
||||
|
||||
public Pair(T var1, U var2) {
|
||||
x = var1;
|
||||
y = var2;
|
||||
}
|
||||
|
||||
public T fst() {
|
||||
return x;
|
||||
}
|
||||
|
||||
public U snd() {
|
||||
return y;
|
||||
}
|
||||
}
|
@ -295,7 +295,6 @@ public abstract class GenerateGenerics {
|
||||
if (optMethod.isEmpty()) return;
|
||||
var method2 = optMethod.get();
|
||||
System.out.println("In: " + method.getName() + " Method: " + method2.getName());
|
||||
System.out.println(simplifiedConstraints);
|
||||
var generics = family(owner, method2);
|
||||
|
||||
// transitive and
|
||||
@ -750,7 +749,6 @@ public abstract class GenerateGenerics {
|
||||
for (var method : classOrInterface.getMethods()) {
|
||||
family(classOrInterface, method);
|
||||
}
|
||||
System.out.println(familyOfMethods);
|
||||
} while(!oldFamily.equals(familyOfMethods));
|
||||
|
||||
for (var method : classOrInterface.getMethods()) {
|
||||
|
Loading…
Reference in New Issue
Block a user