It is because the Arduino IDE uses the list of libraries included in the sketch to know what files to gather together to build the sketch. It can't look inside libraries for that information, only the sketch.
But does that explain why I can put an include file in the sketch that doesn't exist, and not get an error?
Flags can be set to tell the compiler to not output specific messages. The Arduino team has, wrongly in my opinion, set the flag to suppress missing include file errors, even though they are fatal.
I agree Paul, not a good solution. I would never have expected even warnings to be suppressed, since I usually run as treat warnings as errors. But hey... Why else are there flags for that? Somebody must have wanted them. :}
Comparing a signed and an unsigned value generates a warning, without an explicit cast. There are times when neither variable involved can be changed, so the warning is a nuisance. Often, it gets turned off.
Anything that is more than a warning should NOT be turned off, in my opinion.
Huh.. I put in the explicit cast, so I don't have to scan through thousands (yes, I've seen programs that generate thousands of warnings in a full compile) looking for one warning that might or might not be significant. If you keep up with it, adding casts where needed doesn't take that long.
I don't have sympathy for people who turn off warnings and then complain they can't find a bug...