The FunctionScopeInfo stack in Sema uses an optimization where the memory for the top-level functions is reused. The function FunctionScopeInfo::Clear() is used to reset this memory to the original, marking all the flags as false. The flag HasFallthroughStmt was omitted from this, meaning that once it set, it remained so for the rest of the TU. This meant we ran DiagnoseSwitchLabelsFallthrough() for every top level function in a TU where one function used [[fallthrough]].
Thanks!