未定义符号:Swift._StringObject.Variant 的类型元数据,架构 armv7 的未定义符号 - Xcode 12 Beta

ZAF*_*007 7 ios xcode12

我正在尝试通过创建存档,Xcode 12.0 beta但它给了我那个错误。

Undefined symbols for architecture armv7:
  "type metadata for Swift._StringObject.Variant", referenced from:
      outlined init with take of Swift._StringObject.Variant in OpenGraph.Data.o
ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Undefined symbol: type metadata for Swift._StringObject.Variant
Run Code Online (Sandbox Code Playgroud)

我发现这篇文章与该问题有关,但并没有解决我的问题。我创建了存档Xcode 11.6 beta,它没有给我那个错误,但现在苹果在上传二进制文件后给我发送了那封电子邮件。

ITMS-90111: Invalid Toolchain - Your app was built with a beta version of Xcode or SDK. Apps submitted to the App Store must be built with the GM version of Xcode 10.1 and the SDK for iOS 12.1 and watchOS 5.1, Xcode 7.1 and the SDK for tvOS 9, or Xcode 6 and the SDK for macOS 10.9 or later. If you are using an Xcode beta version to test your app, make sure you are using the latest supported version.
Run Code Online (Sandbox Code Playgroud)

谁能告诉我如何在不下载稳定版本的Xcode.

Yog*_*ana 0

我在我的项目中面临同样的问题,我通过替换线下解决了,

如果您使用字符串的前缀或后缀方法,则只需将结果转换为字符串

// Issue code
let pre = self.prefix(0) //self is String object
let suff = self.suffix(4) //self is String object

//Replace with below changes 
let pre = String(self.prefix(0))
let suff = String(self.suffix(4))
Run Code Online (Sandbox Code Playgroud)