UIInterfaceOrientationMaskAll是UIInterfaceOrientationMask枚举定义的一部分
 typedef enum {
       UIInterfaceOrientationMaskPortrait = (1 << UIInterfaceOrientationPortrait),
       UIInterfaceOrientationMaskLandscapeLeft = (1 << UIInterfaceOrientationLandscapeLeft),
       UIInterfaceOrientationMaskLandscapeRight = (1 << UIInterfaceOrientationLandscapeRight),
       UIInterfaceOrientationMaskPortraitUpsideDown = (1 << UIInterfaceOrientationPortraitUpsideDown),
       UIInterfaceOrientationMaskLandscape =
       (UIInterfaceOrientationMaskLandscapeLeft | UIInterfaceOrientationMaskLandscapeRight),
       UIInterfaceOrientationMaskAll =
       (UIInterfaceOrientationMaskPortrait | UIInterfaceOrientationMaskLandscapeLeft |
       UIInterfaceOrientationMaskLandscapeRight | UIInterfaceOrientationMaskPortraitUpsideDown),
       UIInterfaceOrientationMaskAllButUpsideDown =
       (UIInterfaceOrientationMaskPortrait | UIInterfaceOrientationMaskLandscapeLeft |
       UIInterfaceOrientationMaskLandscapeRight),
    } UIInterfaceOrientationMask;
它UIApplication.h在 new 的 the 和 now 部分中定义ios 6 SDK。由于它只是一个整数值,因此您的代码没有理由不应该编译或崩溃。