首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Apple PhotoKit的AVCompositionTrackSegment.h编译错误

Apple PhotoKit的AVCompositionTrackSegment.h编译错误
EN

Stack Overflow用户
提问于 2016-03-28 18:53:03
回答 1查看 148关注 0票数 0

我的项目开始给出一个PhotoKit头的错误,即AVCompositionTrackSegment.h。错误是Expected identifier or '(',它没有指向文件中的任何行。当我将PhotosMediaPlayer框架导入到Swift文件时,就会发生这种情况。我正在使用Xcode 7.3,但我不确定这是否在更新Xcode之前启动。我已经删除了派生数据目录,并完成了一个干净的构建,但没有成功。你知道为什么Xcode会这样被破坏吗?

编辑

卸载应用程序时,开始使用模拟器。但是有了一个真正的设备却没有用。

EN

回答 1

Stack Overflow用户

发布于 2016-03-30 09:51:09

我找到了错误的原因。AVCompantionTrackSegment.h被破坏了。由于某些原因,行@property (nonatomic, readonly, getter=isEmpty) BOOL empty;被替换为&&

编辑

只工作过一次。现在,它在同一文件的空行中给出了“未知类型名称‘”错误。该文件没有错误,因为它已从其他开发人员的计算机还原。

从头文件的末尾删除以下行,现在它编译。所以看起来像Xcode中的一个bug。向苹果提交了一份窃听器报告。

代码语言:javascript
复制
/* indicates whether the AVCompositionTrackSegment is an empty segment;
   an empty segment has a valid target time range but nil sourceURL and kCMTimeInvalid source start time; all other fields are undefined */
@property (nonatomic, readonly, getter=isEmpty) BOOL empty;
​
/* indicates the container file of the media presented by the AVCompositionTrackSegment */
@property (nonatomic, readonly, nullable) NSURL *sourceURL;
​
/* indicates the track of the container file of the media presented by the AVCompositionTrackSegment */
@property (nonatomic, readonly) CMPersistentTrackID sourceTrackID;
票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/36269025

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档