final ArrayList<PyGenericType> results = new ArrayList<PyGenericType>();
for (PyExpression expr : cls.getSuperClassExpressions()) {
if (expr instanceof PySubscriptionExpression) {
final PyExpression indexExpr = ((PySubscriptionExpression)expr).getIndexExpression();
if (indexExpr != null) {
<BUG>final PsiElement resolved = tryResolving(indexExpr, context);
</BUG>
final PyGenericType genericType = getGenericType(resolved, context);
if (genericType != null) {
results.add(genericType);

final ArrayList<PyGenericType> results = new ArrayList<PyGenericType>();
for (PyExpression expr : cls.getSuperClassExpressions()) {
if (expr instanceof PySubscriptionExpression) {
final PyExpression indexExpr = ((PySubscriptionExpression)expr).getIndexExpression();
if (indexExpr != null) {
for (PsiElement resolved : tryResolving(indexExpr, context)) {
final PyGenericType genericType = getGenericType(resolved, context);
if (genericType != null) {
results.add(genericType);
