![]() |
![]() |
|
|
|
|
|
If you download code from Apple you’re likely to see a bunch of lines like #pragma mark FooBar-related functions #pragma mark - A pragma is a directive to the compiler that’s not part of the program itself. According to wikipedia, the term pragma is an abbreviation of pragmatic. There are pragmas for various things like branch prediction hints and such, but I never knew what to make of the “mark” pragma. I figured maybe it placed a comment in the assembly output to help you debug or something. Well thankfully Colin Wheeler posted a blog entry on just this subject. It turns out that pragma mark isn’t for the compiler at all — it’s for XCode! XCode makes a pop-up list of functions and methods in your code to make it easier to find things, but sometimes that list can get very long. If you put It’s a nice tip — thanks Colin!
|
|
![]() |
![]() |



