The single most common formatting mistake I see (many, many times per day) is code like this:
string firstLineIsFine = "yup";
if (firstLineIsFine == "yup")
{
WhyIsEverythingElseMassivelyIndented();
}
While it would be interesting to know exactly what causes this (I suspect it's to do with the way users copy and paste, but I'm not sure), I'd really welcome suggestions on how we could avoid it.
Note that in some languages, it may be deliberate - e.g. a Python question could describe a function, then include that function and the first line would be outdented further than the rest.
Perhaps we could have either a whitelist or blacklist of languages (as determined by tag and/or autodetection) and then on submission, if the system spots the overhang (which should be pretty simple) it could prompt the user to check - perhaps even suggesting an automatic correction.
(I've tagged this as feature-request, but it definitely needs more input before it's a fully-fledged request...)