Lately I keep running into issues where, if I have a sealed class hierarchy that spans multiple files, I'll randomly get a "class A cannot extend class B" thrown at runtime as soon as the program starts, and It won't go away till I make some non-trivial changes to the offending code. My gut reaction is that it has something to do with incremental compilation, but I have no idea. Has anyone else run into this? Any ideas on how to diagnose it next time it strikes?