Xcode 13 beta: cannot find type 'AttributeScopes' in scope

If I try to compile a blank project created from the iOS > App > SwiftUI template, the project doesn't build, due to: cannot find type 'AttributeScopes' in scope errors, eg:

/Applications/Xcode-beta.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/lib/swift/UIKit.swiftmodule/x86_64-apple-ios-simulator.swiftinterface:481:11: error: cannot find type 'AttributeScopes' in scope

extension AttributeScopes {

This happens whether the min target is set to iOS 14 (the default from the template) or iOS 15.

Replies

This is pretty strange, and I wasn't able to reproduce it on my own computer using beta 1. It makes me wonder if there's something unusual about your configuration—maybe you have an open-source Swift toolchain installed or something?

In any case, could you file a bug report for Swift with Feedback Assistant? Please include:

  1. Your project (yes, even though it's just the template)
  2. Although it's not usually necessary for a compiler bug, a sysdiagnose might help with this one
  3. A copy of the build log, exported from here:

Ohhh, it was the toolchain, of course that setting would be imported/shared by the new Xcode version. Thanks for the suggestion :)