]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
vala: No need to run return_type.check() twice for method
authorRico Tzschichholz <ricotz@ubuntu.com>
Fri, 15 Oct 2021 10:02:21 +0000 (12:02 +0200)
committerRico Tzschichholz <ricotz@ubuntu.com>
Fri, 15 Oct 2021 10:22:54 +0000 (12:22 +0200)
vala/valamethod.vala

index f03df3a4c156811a12fec42f87b17abaea0af122..9769efff9eddf6169ebcac7bc9e2d0beacd18656 100644 (file)
@@ -832,10 +832,6 @@ public class Vala.Method : Subroutine, Callable {
                        source_reference.file.context.module_init_method = this;
                }
 
-               if (return_type != null) {
-                       return_type.check (context);
-               }
-
                if (parameters.size == 1 && parameters[0].ellipsis && body != null && binding != MemberBinding.INSTANCE) {
                        // accept just `...' for external methods and instance methods
                        error = true;