]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
Check accessibility of type arguments
authorLuca Bruno <lucabru@src.gnome.org>
Sat, 14 Jan 2012 21:44:30 +0000 (22:44 +0100)
committerLuca Bruno <lucabru@src.gnome.org>
Sat, 14 Jan 2012 22:18:21 +0000 (23:18 +0100)
vala/valadatatype.vala

index c4384bf9a786514fcac17599a72222e4d43f3eba..c553dcf191bc0c5f91b5bc71a77993e91baff837 100644 (file)
@@ -392,6 +392,11 @@ public abstract class Vala.DataType : CodeNode {
 
        // check whether this type is at least as accessible as the specified symbol
        public virtual bool is_accessible (Symbol sym) {
+               foreach (var type_arg in get_type_arguments ()) {
+                       if (!type_arg.is_accessible (sym)) {
+                               return false;
+                       }
+               }
                if (data_type != null) {
                        return data_type.is_accessible (sym);
                }