Fix wrong class generics being used

This commit is contained in:
Victorious3 2023-03-28 13:28:05 +02:00
parent 3963baa9ce
commit 1ad5540500

View File

@ -537,6 +537,7 @@ public class ASTToTargetAST {
var classGenerics = generics(owner); var classGenerics = generics(owner);
var genericsOfClass = classGenerics.javaGenerics(); var genericsOfClass = classGenerics.javaGenerics();
var txGenericsOfClass = classGenerics.txGenerics();
var simplifiedConstraints = new HashSet<>(this.simplifiedConstraints); var simplifiedConstraints = new HashSet<>(this.simplifiedConstraints);
HashSet<TypePlaceholder> txTypeVariables = new HashSet<>(); HashSet<TypePlaceholder> txTypeVariables = new HashSet<>();
@ -545,7 +546,7 @@ public class ASTToTargetAST {
HashSet<TypePlaceholder> javaTypeVariablesOfClass = new HashSet<>(); HashSet<TypePlaceholder> javaTypeVariablesOfClass = new HashSet<>();
methodFindTypeVariables(method, genericsOfClass, javaTypeVariablesOfClass, javaTypeVariables, equality); methodFindTypeVariables(method, genericsOfClass, javaTypeVariablesOfClass, javaTypeVariables, equality);
methodFindTypeVariables(method, genericsOfClass, txTypeVariablesOfClass, txTypeVariables, txEquality); methodFindTypeVariables(method, txGenericsOfClass, txTypeVariablesOfClass, txTypeVariables, txEquality);
methodFindConstraints(owner, method, simplifiedConstraints, javaTypeVariables, classGenerics.userDefinedGenerics, javaTypeVariablesOfClass, javaResult, equality); methodFindConstraints(owner, method, simplifiedConstraints, javaTypeVariables, classGenerics.userDefinedGenerics, javaTypeVariablesOfClass, javaResult, equality);
methodFindConstraints(owner, method, simplifiedConstraints, txTypeVariables, classGenerics.userDefinedGenerics, txTypeVariablesOfClass, txResult, txEquality); methodFindConstraints(owner, method, simplifiedConstraints, txTypeVariables, classGenerics.userDefinedGenerics, txTypeVariablesOfClass, txResult, txEquality);