Use of undeclared identifier 'Serial' clang

Serial.begin(9600); (red underlined)
Using Arduino UNO, receiving this error:
Use of undeclared identifier 'Serial' clang
Beta 8

Please post a complete sketch illustrating the problem. It will show exactly where you have the statement in the code

This is a known issue. You can search this forum category for a lot of discussion on the subject. You just need to expect to get some spurious information like this from the IDE. As long as the compiler is OK with your code, then it's no problem. So just ignore the red squiggly underlines. They really have no meaning.

Thanks,
Yes, it compiles and even code completion works. Nevertheless, it is annoying.
Notably, with the STM32F103 clang does not complain.

Yeah, it is annoying.

I think that the system will be improved over time, but I also encounter these spurious squiggles when working with non-Arduino code (e.g., Go, Python, C++) using other development software that was developed by teams with vastly more resources than Arduino, so this makes me think that there will always be some.

There is a feature request to add a preference to turn it off: