我现在已经遇到这个错误好几次了,我不确定它是什么意思。我试着在网上寻找解决方案,但没有一个专门解决.type的问题。diskCapacity: DISK_CAPACITY, diskPath: "myDiskPath")
URLCache.shared = URLCache //<-Cannot assign value of type'URLCache.type' to type 'URLCache
if False: # TYPE_CHECKING实际上,我目前正在查看,我认为这可能与注释有某种联系,但不确定是如何联系起来的。有没有可能有人会对False进行注释,使其计算结果为True# Constant that's True when type checking, but FalseTYPE_CHECKING = False
所以据我目前所知,@chepner是对的。在运行类型检查时,此语句的计算结果为Tru