forked from JavaTX/JavaCompilerCore
added application of funN Rules
This commit is contained in:
parent
7c0a91e624
commit
b39dedb9aa
@ -292,6 +292,12 @@ public class TypeUnifyTask extends RecursiveTask<Set<Set<UnifyPair>>> {
|
|||||||
// ReduceTphExt, ReduceTphSup
|
// ReduceTphExt, ReduceTphSup
|
||||||
optSet = optSet.isPresent() ? optSet : rules.reduceTphExt(pair);
|
optSet = optSet.isPresent() ? optSet : rules.reduceTphExt(pair);
|
||||||
optSet = optSet.isPresent() ? optSet : rules.reduceTphSup(pair);
|
optSet = optSet.isPresent() ? optSet : rules.reduceTphSup(pair);
|
||||||
|
|
||||||
|
|
||||||
|
// FunN Rules
|
||||||
|
optSet = optSet.isPresent() ? optSet : rules.reduceFunN(pair);
|
||||||
|
optSet = optSet.isPresent() ? optSet : rules.greaterFunN(pair);
|
||||||
|
optSet = optSet.isPresent() ? optSet : rules.smallerFunN(pair);
|
||||||
|
|
||||||
// One of the rules has been applied
|
// One of the rules has been applied
|
||||||
if(optSet.isPresent()) {
|
if(optSet.isPresent()) {
|
||||||
@ -436,7 +442,11 @@ public class TypeUnifyTask extends RecursiveTask<Set<Set<UnifyPair>>> {
|
|||||||
candidateParams.add(fc.grArg(param));
|
candidateParams.add(fc.grArg(param));
|
||||||
|
|
||||||
for(TypeParams tp : permuteParams(candidateParams))
|
for(TypeParams tp : permuteParams(candidateParams))
|
||||||
|
try {
|
||||||
thetaQPrimes.add(c.setTypeParams(tp));
|
thetaQPrimes.add(c.setTypeParams(tp));
|
||||||
|
} catch(Exception e) {
|
||||||
|
System.out.println("f");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
for(UnifyType tqp : thetaQPrimes) {
|
for(UnifyType tqp : thetaQPrimes) {
|
||||||
|
Loading…
Reference in New Issue
Block a user