I'm experiencing the same problem on macOS 15.6 and latest Xcode. I've tried all the incantations of cleaning the build folder, quitting and re-launching, deleting the derived data, etc. I also deleted and re-installed Xcode from the App Store, but still no joy. I'll try downloading Xcode from the Developer website next and see if that works.
Topic:
Developer Tools & Services
SubTopic:
Xcode
Tags: