在手机上编译应用程序时遇到一些错误。它在模拟器中可以正常工作,但不能用于其他任何事情。重置设备设置后开始。我尝试创建一个新项目,但这没有用。这是确切的错误。
<module-includes>:1:9: note: in file included from <module-includes>:1:
#import "dispatch.h"
^
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS12.1.sdk/usr/include/dispatch/dispatch.h:48:2: error: module 'ObjectiveC' in AST file
<module-includes>:1:9: note: in file included from <module-includes>:1:
#import "Headers/CoreFoundation.h"
^
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS12.1.sdk/System/Library/Frameworks/CoreFoundation.framework/Headers/CoreFoundation.h:60:10: note: in file included from /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS12.1.sdk/System/Library/Frameworks/CoreFoundation.framework/Headers/CoreFoundation.h:60:
#include <CoreFoundation/CFPropertyList.h>
^
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS12.1.sdk/System/Library/Frameworks/CoreFoundation.framework/Headers/CFPropertyList.h:17:10: note: in file included from /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS12.1.sdk/System/Library/Frameworks/CoreFoundation.framework/Headers/CFPropertyList.h:17:
#include <CoreFoundation/CFStream.h>
^
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS12.1.sdk/System/Library/Frameworks/CoreFoundation.framework/Headers/CFStream.h:20:10: error: could not build module 'Dispatch'
#include <dispatch/dispatch.h>
^
<unknown>:0: error: could not build Objective-C module 'CoreFoundation'
这似乎不是与代码相关的问题,因为该代码在前几天编译时没有任何问题。我只是不确定如何解决它。