Object as default bound

This commit is contained in:
Victorious3 2023-03-01 12:02:01 +01:00
parent c0348ed304
commit 3de89a5cfa

View File

@ -2,6 +2,7 @@ package de.dhbwstuttgart.parser.SyntaxTreeGenerator;
import de.dhbwstuttgart.exceptions.NotImplementedException;
import de.dhbwstuttgart.exceptions.TypeinferenceException;
import de.dhbwstuttgart.parser.NullToken;
import de.dhbwstuttgart.parser.antlr.Java8Parser;
import de.dhbwstuttgart.parser.antlr.Java8Parser.UnannClassType_lfno_unannClassOrInterfaceTypeContext;
import de.dhbwstuttgart.parser.scope.GenericsRegistry;
@ -169,7 +170,7 @@ public class TypeGenerator {
return new SuperWildcardType(convert(wildcardContext.wildcardBounds().referenceType(), reg, generics), wildcardContext.getStart());
}
}else{
throw new NotImplementedException(); //Wildcard ohne Bound
return new ExtendsWildcardType(new RefType(new JavaClassName("Object"), new NullToken()), wildcardContext.getStart());
}
}