Xcode - Using #pragma mark

后端 未结 2 656
梦毁少年i
梦毁少年i 2021-02-05 05:42

I\'m pretty sure this isn\'t a duplicate. Do you use #pragma mark? I\'ve seen multiple ways, which is correct?

#pragma mark -
#pragma mark === Actions ===
#pragm         


        
2条回答
  •  陌清茗
    陌清茗 (楼主)
    2021-02-05 06:17

    if use like this

    #pragma mark -
    #pragma mark Actions
    

    or this

    #pragma mark - Actions
    

    xcode will add one separator and bold text line Actions.

    BUT if you add one more space after minus - xcode will create two separators one by one...

    #pragma mark -SPACEHERE
    #pragma mark Actions
    

    :)

提交回复
热议问题