]> 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:19:29 +0000 (14:19 +0200)
vala/valagenieparser.vala
vala/valaparser.vala

index 43ff863de3a847c923656a7ae591ce31753c3efa..aacbacecadbaf174a962becf3a6cad741b9db020 100644 (file)
@@ -3515,6 +3515,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 fcfa33483e9b97ee108fcbd063588416f68254b5..84f1f39a04435857e3a1b49243bbe37d11387c67 100644 (file)
@@ -3440,6 +3440,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 ();