Why can't Xcode find symbols in scope, but still compiles?

My swiftUI project has started to constantly display "Cannot find 'symbol' in scope" errors in code i haven't touched, and the project still compiles fine. Neither cleaning build folder or compiling fix the errors, but if I right click the symbol, select "jump to definition" it will find it without problem and then when I return to the original file the error will be cleared.

What can I do to stop these from happening?

Why can't Xcode find symbols in scope, but still compiles?
 
 
Q