changeset 3988:3e22fe67fa69 v7.3.749

updated for version 7.3.749 Problem: Python interface doesn't build without the multi-byte feature. Solution: Add #ifdef. (Ken Takata)
author Bram Moolenaar <bram@vim.org>
date Wed, 05 Dec 2012 16:30:07 +0100
parents 73bb286f9091
children 953a4672434a
files src/if_py_both.h src/version.c
diffstat 2 files changed, 9 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/if_py_both.h
+++ b/src/if_py_both.h
@@ -520,7 +520,13 @@ VimStrwidth(PyObject *self UNUSED, PyObj
     if (!PyArg_ParseTuple(args, "s", &expr))
 	return NULL;
 
-    return PyLong_FromLong(mb_string2cells((char_u *)expr, (int)STRLEN(expr)));
+    return PyLong_FromLong(
+#ifdef FEAT_MBYTE
+	    mb_string2cells((char_u *)expr, (int)STRLEN(expr))
+#else
+	    STRLEN(expr)
+#endif
+	    );
 }
 
 /*
--- a/src/version.c
+++ b/src/version.c
@@ -726,6 +726,8 @@ static char *(features[]) =
 static int included_patches[] =
 {   /* Add new patch number below this line */
 /**/
+    749,
+/**/
     748,
 /**/
     747,