我刚刚升级到 Xcode 16.0 和 Sequoia 15.0。我有一个大型的、主要是 Objective-C 的项目,它给了我以下错误。有谁知道我如何追踪这个错误?我很想创建一个示例项目来重现它,但我不知道我的项目的哪一部分正在使编译器走上这条路。其他项目构建良好。
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.0.sdk/usr/include/wchar.h:67:10: note: while building module '\_wchar' imported from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.0.sdk/usr/include/wchar.h:67:
#include \<\_wchar.h\>
^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.0.sdk/usr/include/\_wchar.h:76:10: note: while building module '\__wctype' imported from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.0.sdk/usr/include/\_wchar.h:76:
#include \<sys/\_types/\_mbstate_t.h\>
^
\<module-includes\>:1:9: note: in file included from \<module-includes\>:1:
#import "\___wctype.h"
^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.0.sdk/usr/include/\___wctype.h:83:24: error: use of undeclared identifier '\_CTYPE_A'
return (\__istype(\_wc, \_CTYPE_A|\_CTYPE_D));
^
有 100 多行类似错误引用 _CTYPE_A、_CTYPE_C、_CTYPE_D、_CTYPE_G 等。
我已经在另一台仍在运行 Sonoma 的 Mac 上对此进行了测试。该项目在该计算机上使用 Xcode 15.4 进行编译,但使用 Xcode 16 会出现相同的错误。