]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
parser: Implicit "main" method of main-block is public and static
authorRico Tzschichholz <ricotz@ubuntu.com>
Sun, 24 Nov 2019 21:42:18 +0000 (22:42 +0100)
committerRico Tzschichholz <ricotz@ubuntu.com>
Sun, 24 Nov 2019 21:42:18 +0000 (22:42 +0100)
vala/valaparser.vala

index 587f6b159e8c32f2ef76dac532c8a96e86e2ede9..e6c667bca621c4ea2fc609f201dc6e1586e2a250 100644 (file)
@@ -2261,6 +2261,8 @@ public class Vala.Parser : CodeVisitor {
                var begin = get_location ();
 
                var method = new Method ("main", new VoidType (), get_src (begin));
+               method.access = SymbolAccessibility.PUBLIC;
+               method.binding = MemberBinding.STATIC;
                method.body = new Block (get_src (begin));
                parse_statements (method.body);
                if (current () != TokenType.EOF) {