Resolve property initializer if there is no primary constructor

This commit is contained in:
Denis Zharkov
2015-02-18 17:43:14 +03:00
parent a872a51a19
commit 4c26d037d9
4 changed files with 20 additions and 4 deletions
@@ -530,10 +530,7 @@ public class BodyResolver {
JetExpression initializer = property.getInitializer();
JetScope propertyScope = getScopeForProperty(c, property);
if (initializer != null) {
ConstructorDescriptor primaryConstructor = classDescriptor.getUnsubstitutedPrimaryConstructor();
if (primaryConstructor != null) {
resolvePropertyInitializer(c, property, propertyDescriptor, initializer, propertyScope);
}
resolvePropertyInitializer(c, property, propertyDescriptor, initializer, propertyScope);
}
JetExpression delegateExpression = property.getDelegateExpression();