For example, C and C++ still cannot compile this:
int foo() { return bar(); }
int bar() { return 3; } int foo() { return bar(); }
int bar() { return 3; }And even if that isn't a problem, given how ISO works, someone still needs to get that paper in and voted.
It has deleterious consequences. One solution is to add a forward declaration, which is the kind of busywork a language is supposed to eliminate.
Another is to reverse the natural order of functions, with the implementation functions at the top and the interface of the module at the bottom.
After all, do you read a website from top to bottom or bottom to top?
So I guess I kind of prefer seeing helper functions at the top and the main logic at the bottom most of the time.