Prefix.pch 文件的使用

来源:互联网 发布:python 新浪财经接口 编辑:程序博客网 时间:2024/05/16 07:34

在我们创建的xCode项目中,将会有个文件:XXX-Prefix.pch 文件。


1.Prefix.pch 是什么文件?

Prefix.pch 就是“precompiled header” ,也就是预编译文件!


2.Prefix.pch文件有什么用途?

当项目需要编译时,xCode将编译Prefix.pch 文件中的内容。
实际应用中,我们在Prefix.pch中定义变量或者宏;这样,我们在整个项目中都可以使用在Prefix.pch文件中的变量,或者是宏。


0 0
原创粉丝点击