Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8628753
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T08:37:43+00:00 2026-06-12T08:37:43+00:00

I have an iOS 5 application, now built with Xcode 4.5, I am running

  • 0

I have an iOS 5 application, now built with Xcode 4.5, I am running it on iphone 5.0 simulator.
The Xcode target is correctly set to iOS 5, while the base sdk is iOS 6, and there’s no way to change within Xcode.
There’s a fragment of code which made use of the enum.

UIInterfaceOrientationMaskAll

I am not really using that enum in my code, it’s a mistake I did, that lead me to ask some questions:

  1. I would expect the compiler stop building, because it’s available starting from iOS 6, and telling me that the enum is not to be found.

  2. Then, by running the app in simulator (iphone 5.0 simulator), I would also expect the app crashing at runtime when dealing with that enum.

Nothing of that is hapenning, and the app compile and runs just fine, could you please explain what am I missing ?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T08:37:44+00:00Added an answer on June 12, 2026 at 8:37 am

    Here’s my explanation.

    Looking at the documentation, all the UIInterfaceOrientation values are available from iOS 6.0. You are supposed to return them from UIApplication‘s supportedInterfaceOrientationsForWindow:, which is also available from iOS 6.0.

    Since your base SDK is 6.0, you have the new version of the header file (UIApplication.h) that defines the enum value. That’s why your app compiles.

    When you run the app on the iPhone 5.0 simulator, nobody ever calls the aforementioned method, because it didn’t exist in 5.0. Even if you had subclassed UIApplication, and had implemented that method, it wouldn’t be called, so your app won’t crash with unknown selector. It could also be implemented by your app delegate.

    Also, the enum value is just a number after compilation anyway, so there is no “dealing with” that would cause a problem, unlike missing interfaces would.

    But if I’m totally off base, I’m sure somebody will set me straight.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a view-based iOS cocoa touch application built and is running on iPhone.
I am developing an application for ios 5.1. I have now set up push
I have recently installed xcode 4.5 for iOS 6 SDK, but now when I
I have an IOS application which uses environment variables and am able to set
i have installed new Xcode 4.2 with ios 5.0 beta . Now I have
I have built an android app and now its time to built an IOS
i have ios application with xcdatamodeld, i want update some data so need a
I have ios application with datetimepicker, and i am store the date in to
i have an iOS application witch uses the current location of the user. I
I have an iOS application with several controllers, each with their own xib files.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.