]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
valainterface: Don't allow 'type' properties
authorTimm Bäder <mail@baedert.org>
Tue, 27 Oct 2015 08:47:58 +0000 (09:47 +0100)
committerRico Tzschichholz <ricotz@ubuntu.com>
Sat, 17 Sep 2016 20:22:27 +0000 (22:22 +0200)
https://bugzilla.gnome.org/show_bug.cgi?id=723258

vala/valainterface.vala

index 621c6e8ce16c050f5193f3ba475d54a7a2b3f1f8..f80427b98d9b844f41477a431aabbf191c05819d 100644 (file)
@@ -204,6 +204,11 @@ public class Vala.Interface : ObjectTypeSymbol {
                        return;
                }
 
+               if (prop.name == "type") {
+                       Report.error (prop.source_reference, "Property 'type' not allowed");
+                       return;
+               }
+
                properties.add (prop);
                scope.add (prop.name, prop);