Even though the global variable is defined after the function definition where it is used, the function has complete visibility of its surrounding scope. So this test should succeed.
@@ -1,5 +0,0 @@
-int foo() {
- return glob; // glob is not yet defined here
-}
-
-int glob;
@@ -0,0 +1,5 @@
+int foo() {
+ return glob; // OK, surrounding scope is fully visible.
+}
+
+int glob;