@import vs #import - iOS 7

后端 未结 6 1197
小蘑菇
小蘑菇 2020-11-22 14:44

I am playing around with some of the new iOS 7 features and working with some of the Image Effects as discussed in the WWDC video \"Implementing Engaging UI on iOS\". For pr

6条回答
  •  不知归路
    2020-11-22 15:20

    History:

    #include => #import => .pch => @import
    

    #include vs #import
    .pch - Precompiled header

    Module - @import

    Product Name == Product Module Name 
    

    @import module declaration says to compiler to load a precompiled binary of framework which decrease a building time. Modular Framework contains .modulemap[About]

    If module feature is enabled in Xcode project #include and #import directives are automatically converted to @import that brings all advantages

提交回复
热议问题