Defining "bool? { owned get; set; }" in a GObject class resulted in:
"error: The type `bool' doesn't declare a GValue take function"
Fixes a regression of
3af1cfb3bf6b1d3d4a8116382e6eda702f7335bf and reverts
to the old behavior for nullable simple-type structs.
objects/property-construct-only-write-foreign.test \
objects/property-gboxed-nullable.vala \
objects/property-real-struct-no-accessor.test \
+ objects/property-simple-type-struct-nullable.vala \
objects/property-static.vala \
objects/regex.vala \
objects/signals.vala \
--- /dev/null
+public class Foo : Object {
+ public bool? bar { owned get; set; }
+}
+
+void main () {
+}
public bool is_gobject_property_type (DataType property_type) {
var st = property_type.data_type as Struct;
if (st != null) {
- if (st.get_attribute_bool ("CCode", "has_type_id", true)) {
+ if (!st.is_simple_type () && st.get_attribute_bool ("CCode", "has_type_id", true)) {
// Allow GType-based struct types
} else if (property_type.nullable) {
return false;