Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What does this mean in iphone programming?

#pragma mark Internal API 

I've seen this in a book called xcode_quick_tour_iphoneOS.

Does someone know about it?

like image 994
Rahul Vyas Avatar asked Apr 25 '09 15:04

Rahul Vyas


People also ask

What is coded in iPhone?

Swift is a robust and intuitive programming language created by Apple for building apps for iOS, Mac, Apple TV, and Apple Watch.

How is iOS coded?

IOS is written in SWIFT which is created and maintained by APPLE itself. 99% of Software's made by APPLE are Developed in SWIFT like macOS, tvOS, watchOS.. I want to correct you a little bit here. iPhone is a Device which runs IOS software and connects it with Hardware makes your work simpler.

Can iPhone be used for programming?

While most developers use popular IDEs like Xcode and Sublime Text on their Macs, few realize that their iPhones and iPads can also handle coding apps.


1 Answers

The #pragma directive is a special pre-processor directive that allows the C pre-processor a way to pretty much create "portable" extensions. Basically, when another pre-processor sees a pragma directive that it doesn't understand, it's supposed to ignore it.

In this case, #pragma mark is meant to aid in documentation. When you add those lines to your source file, Xcode will break up your source code in its jump-to pull-down menu that you can use to jump to specific areas in your code (like function definitions or constant definitions). If you add #pragma mark -, Xcode will add a horizontal separator to the pull-down menu as well.

like image 71
Jason Coco Avatar answered Oct 08 '22 11:10

Jason Coco