[vala] GObject: Check for incompatible properties in constructor chain up
- From: Jürg Billeter <juergbi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vala] GObject: Check for incompatible properties in constructor chain up
- Date: Sat, 16 Oct 2010 12:19:45 +0000 (UTC)
commit 644cca0e443f216e8e5e26fab14bb6428e70cda8
Author: Jürg Billeter <j bitron ch>
Date: Sat Oct 16 14:18:08 2010 +0200
GObject: Check for incompatible properties in constructor chain up
Fixes bug 622119.
codegen/valagobjectmodule.vala | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/codegen/valagobjectmodule.vala b/codegen/valagobjectmodule.vala
index f30077c..89c4834 100644
--- a/codegen/valagobjectmodule.vala
+++ b/codegen/valagobjectmodule.vala
@@ -772,6 +772,10 @@ public class Vala.GObjectModule : GTypeModule {
Report.error (arg.source_reference, "Property `%s' not found in `%s'".printf (named_argument.name, current_class.get_full_name ()));
break;
}
+ if (!is_gobject_property (prop)) {
+ Report.error (arg.source_reference, "Property `%s' not supported in Object (property: value) constructor chain up".printf (named_argument.name));
+ break;
+ }
if (!arg.value_type.compatible (prop.property_type)) {
Report.error (arg.source_reference, "Cannot convert from `%s' to `%s'".printf (arg.value_type.to_string (), prop.property_type.to_string ()));
break;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]