The default value is passed to the GParamSpec. The property will not
implicitly be set to the default value during object construction
unless it is a construct property.
prop.field = new Field ("_%s".printf (prop.name), variable_type, prop.initializer, prop.source_reference);
prop.field.access = SymbolAccessibility.PRIVATE;
prop.field.binding = prop.binding;
- } else if (prop.initializer != null) {
- Report.error (prop.initializer.source_reference, "only automatic properties can have default values");
}
}