ResultSet kann GenericRefTypes auflösen

This commit is contained in:
JanUlrich 2017-12-20 15:01:02 +01:00
parent 09bdaa6a21
commit 940c922c80

View File

@ -1,6 +1,7 @@
package de.dhbwstuttgart.typeinference.result;
import de.dhbwstuttgart.exceptions.NotImplementedException;
import de.dhbwstuttgart.syntaxtree.GenericTypeVar;
import de.dhbwstuttgart.syntaxtree.type.*;
import java.util.HashSet;
@ -15,6 +16,7 @@ public class ResultSet {
public ResolvedType resolveType(RefTypeOrTPHOrWildcardOrGeneric type) {
if(type instanceof TypePlaceholder)
return new Resolver(this).resolve((TypePlaceholder)type);
if(type instanceof GenericRefType)new ResolvedType(type, new HashSet<>());
if(type instanceof RefType){
RelatedTypeWalker related = new RelatedTypeWalker(null, this);
type.accept(related);