Use stubs in has* methods of JetProperty

This commit is contained in:
Pavel V. Talanov
2014-04-09 15:46:31 +04:00
parent 736465f1c6
commit 86ac8bbd65
@@ -147,6 +147,10 @@ public class JetProperty extends JetTypeParameterListOwnerStub<PsiJetPropertyStu
}
public boolean hasDelegate() {
PsiJetPropertyStub stub = getStub();
if (stub != null) {
return stub.hasDelegate();
}
return getDelegate() != null;
}
@@ -156,6 +160,10 @@ public class JetProperty extends JetTypeParameterListOwnerStub<PsiJetPropertyStu
}
public boolean hasDelegateExpression() {
PsiJetPropertyStub stub = getStub();
if (stub != null) {
return stub.hasDelegateExpression();
}
return getDelegateExpression() != null;
}
@@ -169,6 +177,10 @@ public class JetProperty extends JetTypeParameterListOwnerStub<PsiJetPropertyStu
}
public boolean hasInitializer() {
PsiJetPropertyStub stub = getStub();
if (stub != null) {
return stub.hasInitializer();
}
return getInitializer() != null;
}