I might be a bit of a noob here, but isn’t it pretty standard for any ANSI C derivative languages to allow the functions to be pretty much anywhere in the file, and have the compiler still find them?

As fair as I understood; the Arduino framework is just a bunch of libraries on top of C++, so it seems a bit odd to me that we need to put ISR defs above setup(). Also by my interweb suggests that the people using the vanilla Arduino IDE (gcc IIRC) aren’t having this problem.

Could someone please clarify what’s going on, or point me to what I’m missing? Is this simply a “gcc vs Visual Studio” thing, or some kind of an ANSI-compliance thing?

You can put them anywhere in the file if you first declare their existence before they are used for the first time. If the compiler doesn’t know about the existence of the function before it encounters it’s first use, it will spit the dummy.

The Arduino IDE has a preprocessor system (Arduino builder) which does things in a non-C/C+±standard manner - such as generating function prototypes itself, and mashing all the open tabs in a sketch together, making it a single file.

It’s just easier to shove the setup and loop at the end of the file, then you don’t need to declare prototypes at all since they’ll have all defined by the time they are called in setup or loop.