]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
parser: Make sure ErrorCodes are accessible as needed
authorRico Tzschichholz <ricotz@ubuntu.com>
Sat, 23 Oct 2021 13:27:12 +0000 (15:27 +0200)
committerRico Tzschichholz <ricotz@ubuntu.com>
Sun, 24 Oct 2021 12:57:31 +0000 (14:57 +0200)
vala/valagenieparser.vala
vala/valaparser.vala

index 45e0d97290beb317e37d230282c5cf18e082857c..a96d180311cadbb23b4050a72514d2a8d2c398ee 100644 (file)
@@ -3494,6 +3494,7 @@ public class Vala.Genie.Parser : CodeVisitor {
                        string id = parse_identifier ();
                        comment = scanner.pop_comment ();
                        var ec = new ErrorCode (id, get_src (code_begin), comment);
+                       ec.access = SymbolAccessibility.PUBLIC;
                        set_attributes (ec, code_attrs);
                        if (accept (TokenType.ASSIGN)) {
                                ec.value = parse_expression ();
index 97406a9574e61eb87ae90539c9511187c27f9c16..33e6418cffc74b82725680fc3c72b5b8037dc993 100644 (file)
@@ -3326,6 +3326,7 @@ public class Vala.Parser : CodeVisitor {
                        }
 
                        var ec = new ErrorCode (id, get_src (code_begin), comment);
+                       ec.access = SymbolAccessibility.PUBLIC;
                        set_attributes (ec, code_attrs);
                        if (accept (TokenType.ASSIGN)) {
                                ec.value = parse_expression ();