Xcode16 Archive Error - Command SwiftCompile failed with a nonzero exit code

1.打包错误信息

Command SwiftCompile failed with a nonzero exit code

2.找到原因

It's because in Xcode 16, UITextField, they add a new function with the same name onReturn. It's ok when you compile and run, but will return error DeadArgSignatureOpt when archive.

The workaround is to change it to a different name (ex: onReturns)

(UITextField 新增了一个函数方法:onReturn;与三方库里面的onReturn函数方法冲突了,改下三方库里的名字即可,例如:onReturns)

3.解决

修改完打包,pass!

相关推荐
皇上o_O2 小时前
深入理解 Swift Concurrency:从 async/await 到隔离域
ios
CocoaKier4 小时前
1月12日最新用户隐私保护政策出炉,政策解读
ios
Mr -老鬼8 小时前
移动端跨平台适配技术框架:从发展到展望
android·ios·小程序·uni-app
tiantian_cool1 天前
Claude Code 四大核心技能使用指南
ios
冰淇淋真好吃1 天前
iOS实现 WKWebView 长截图的优雅方案
ios
njsgcs1 天前
Swift playground 网页刷新切换随机页面的网页查看器WebKit
swift
前端不太难1 天前
Flutter / RN / iOS,在长期维护下的性能差异本质
flutter·ios
搜狐技术产品小编20232 天前
精通 UITableViewDiffableDataSource——从入门到重构的现代 iOS 列表开发指南
ios·重构
tangweiguo030519872 天前
SwiftUI 状态管理完全指南:从 @State 到 @EnvironmentObject
ios
声网2 天前
如何用 Fun-ASR-Nano 微调一个「听懂行话」的语音模型?丨Voice Agent 学习笔记
笔记·学习·xcode