代码之家  ›  专栏  ›  技术社区  ›  Georg Schölly Crazy Developer

常量“SomeString”有什么特别之处?

  •  1
  • Georg Schölly Crazy Developer  · 技术社区  · 16 年前

    例子:

    FOUNDATION_EXPORT NSString * const NSLocalNotificationCenterType;
    

    通过该类型限定符更改了什么?我明白了,如果 const

    1 回复  |  直到 16 年前
        1
  •  5
  •   Carl Norum    16 年前

    这个 const 之后 *

    NSString *myString = @"abcde";
    NSLocalNotificationCenterType = myString;