This is the same problem as this one:
The Swift interface of the iOS 17 SDK is broken and needs a manual fix documented here. This fix will be automated in the next version of the builder. Apple is probably not aware of this because they supply precompiled Swift modules with Xcode, so the compiler infrastructure doesn't need to recompile the Swift interfaces of the SDK into Swift modules.