On Wed, Jul 17, 2024 at 6:38 PM João Távora wrote: > > > Anyway, can you try this patch? > > > > That seems to work too :) > > I understand the source of _this_ problem, and the line I changed > addresses it. My worry is that my fix also creates more problems, > but it seems cleaner. Indeed it did create some subtle problems with "foreign diagnostics". I made a better patch, attached. It should fix the Eglot/flymake-cc scenario and be a net improvement for Flymake. Also adds a new Flymake test. Spencer please have a look and push it if you agree. João