forked from aniani/vim
patch 8.1.1020: compiler warning for Python3 interface
Problem: Compiler warning for Python3 interface. Solution: Add type cast. (Ozaki Kiichi, closes #4128, closes #4103)
This commit is contained in:
parent
4eefe47ea4
commit
828bff1f9b
@ -799,10 +799,11 @@ static struct PyModuleDef vimmodule;
|
||||
*/
|
||||
#include "if_py_both.h"
|
||||
|
||||
// NOTE: Must always be used at the start of a block, since it declares "name".
|
||||
#define GET_ATTR_STRING(name, nameobj) \
|
||||
char *name = ""; \
|
||||
if (PyUnicode_Check(nameobj)) \
|
||||
name = _PyUnicode_AsString(nameobj)
|
||||
name = (char *)_PyUnicode_AsString(nameobj)
|
||||
|
||||
#define PY3OBJ_DELETED(obj) (obj->ob_base.ob_refcnt<=0)
|
||||
|
||||
|
@ -779,6 +779,8 @@ static char *(features[]) =
|
||||
|
||||
static int included_patches[] =
|
||||
{ /* Add new patch number below this line */
|
||||
/**/
|
||||
1020,
|
||||
/**/
|
||||
1019,
|
||||
/**/
|
||||
|
Loading…
x
Reference in New Issue
Block a user