From d7760807dd141a41daff8efed7d4382e1f672e4f Mon Sep 17 00:00:00 2001 From: ichizok Date: Mon, 26 Mar 2018 21:43:58 +0900 Subject: [PATCH] Check if method exists, not using macro condition macro condition depends on MACOSX_DEPLOYMENT_TARGET variable --- src/MacVim/gui_macvim.m | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/MacVim/gui_macvim.m b/src/MacVim/gui_macvim.m index 3b573329ad..079f265e38 100644 --- a/src/MacVim/gui_macvim.m +++ b/src/MacVim/gui_macvim.m @@ -285,14 +285,12 @@ [[MMBackend sharedInstance] addToMRU:filenames]; } -#if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_10 - { + if ([NSProcessInfo instancesRespondToSelector:@selector(isOperatingSystemAtLeastVersion:)]) { NSOperatingSystemVersion version = {10, 13, 0}; is_macos_high_sierra_or_later = [[NSProcessInfo processInfo] isOperatingSystemAtLeastVersion:version]; } -#endif return OK; }