Fixed a stupid regression in getType() introduced in 216282.

This commit is contained in:
Dmitry Cheryasov
2008-12-06 14:38:14 +03:00
parent 80d7945468
commit 9badd978e4
@@ -148,7 +148,7 @@ public class PyCallExpressionImpl extends PyElementImpl implements PyCallExpress
PyExpression callee = getCallee();
if (callee instanceof PyReferenceExpression) {
ResolveResult[] targets = ((PyReferenceExpression)callee).multiResolve(false);
if (targets.length == 0) {
if (targets.length > 0) {
PsiElement target = targets[0].getElement();
if (target instanceof PyClass) {
return new PyClassType((PyClass) target, false); // we call a class name, that is, the constructor, we get an instance.