private static IEnumerable<PythonType> GetPythonTypes(string typeName, ICollection<object> bases) {
foreach (object curBaseType in bases) {
PythonType curBasePythonType = curBaseType as PythonType;
if (curBasePythonType == null) {
if (curBaseType is OldClass)
continue;
throw PythonOps.TypeError(typeName + ": unsupported base type for new-style class " + curBaseType);
}
yield return curBasePythonType;
}
}