import java.util.Vector; import java.lang.Boolean; import java.lang.Object; class Pair { U a; T b; make(x) { var ret = new Pair<>(); ret.a = x.elementAt(0); ret.b = x.elementAt(1); return ret; } eq(a, b) { b = a; return a == b; } compare( p) { return eq(p.a, p.b); //return p.a == p.b; } /* void m(Pair p, List b) { //this.compare(p); //1, type incorrect this.compare(this.make(b)); //2, OK } */ }