summaryrefslogtreecommitdiffstats
path: root/src/if_python.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2017-10-28 21:11:06 +0200
committerBram Moolenaar <Bram@vim.org>2017-10-28 21:11:06 +0200
commitd057301b1f28736f094affa17b190244ad56e8d9 (patch)
treeae20801354321a5ff0d7d23b04d8d6018c57645a /src/if_python.c
parentef83956e1e67736b4c6b886d897b74f022622a74 (diff)
patch 8.0.1236: Mac features are confusingv8.0.1236
Problem: Mac features are confusing. Solution: Make feature names more consistent, add "osxdarwin". Rename feature flags, cleanup Mac code. (Kazunobu Kuriyama, closes #2178)
Diffstat (limited to 'src/if_python.c')
-rw-r--r--src/if_python.c20
1 files changed, 0 insertions, 20 deletions
diff --git a/src/if_python.c b/src/if_python.c
index cbc7d97b91..f9fc5e1a5b 100644
--- a/src/if_python.c
+++ b/src/if_python.c
@@ -70,10 +70,6 @@
# undef PY_SSIZE_T_CLEAN
#endif
-#if defined(MACOS) && !defined(MACOS_X_UNIX)
-# include "macglue.h"
-# include <CodeFragments.h>
-#endif
#undef main /* Defined in python.h - aargh */
#undef HAVE_FCNTL_H /* Clash with os_win32.h */
@@ -948,11 +944,7 @@ Python_Init(void)
Py_NoSiteFlag++;
#endif
-#if !defined(MACOS) || defined(MACOS_X_UNIX)
Py_Initialize();
-#else
- PyMac_Initialize();
-#endif
#if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02070000
/* 'import site' explicitly. */
@@ -1024,9 +1016,6 @@ DoPyCommand(const char *cmd, rangeinitializer init_range, runner run, void *arg)
#ifndef PY_CAN_RECURSE
static int recursive = 0;
#endif
-#if defined(MACOS) && !defined(MACOS_X_UNIX)
- GrafPtr oldPort;
-#endif
#if defined(HAVE_LOCALE_H) || defined(X_LOCALE)
char *saved_locale;
#endif
@@ -1045,12 +1034,6 @@ DoPyCommand(const char *cmd, rangeinitializer init_range, runner run, void *arg)
if (python_end_called)
return;
-#if defined(MACOS) && !defined(MACOS_X_UNIX)
- GetPort(&oldPort);
- /* Check if the Python library is available */
- if ((Ptr)PyMac_Initialize == (Ptr)kUnresolvedCFragSymbolAddress)
- goto theend;
-#endif
if (Python_Init())
goto theend;
@@ -1099,9 +1082,6 @@ DoPyCommand(const char *cmd, rangeinitializer init_range, runner run, void *arg)
Python_Lock_Vim(); /* enter vim */
PythonIO_Flush();
-#if defined(MACOS) && !defined(MACOS_X_UNIX)
- SetPort(oldPort);
-#endif
theend:
#ifndef PY_CAN_RECURSE