Forgot #undefs, add python bad names, change names from

tclkw.swg and phpkw.swg to the right ones tcl8kw.swg and php8kw.swg.


git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@5546 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
Marcelo Matus 2003-12-12 06:15:46 +00:00
commit 8e8e0ce6e8
9 changed files with 99 additions and 51 deletions

View file

@ -2,36 +2,67 @@
#define __python_pythonkw_swg__
/* Warnings for Python keywords */
#define PYKW(x) %namewarn("314:" #x " is a python keyword") #x
#define PYTHONKW(x) %namewarn("314:" #x " is a python keyword") #x
PYKW(and);
PYKW(assert);
PYKW(break);
PYKW(class);
PYKW(continue);
PYKW(def);
PYKW(del);
PYKW(elif);
PYKW(else);
PYKW(except);
PYKW(exec);
PYKW(finally);
PYKW(for);
PYKW(from);
PYKW(global);
PYKW(if);
PYKW(import);
PYKW(in);
PYKW(is);
PYKW(lambda);
PYKW(not);
PYKW(or);
PYKW(pass);
PYKW(print);
PYKW(raise);
PYKW(return);
PYKW(try);
PYKW(while);
PYTHONKW(and);
PYTHONKW(assert);
PYTHONKW(break);
PYTHONKW(class);
PYTHONKW(continue);
PYTHONKW(def);
PYTHONKW(del);
PYTHONKW(elif);
PYTHONKW(else);
PYTHONKW(except);
PYTHONKW(exec);
PYTHONKW(finally);
PYTHONKW(for);
PYTHONKW(from);
PYTHONKW(global);
PYTHONKW(if);
PYTHONKW(import);
PYTHONKW(in);
PYTHONKW(is);
PYTHONKW(lambda);
PYTHONKW(not);
PYTHONKW(or);
PYTHONKW(pass);
PYTHONKW(print);
PYTHONKW(raise);
PYTHONKW(return);
PYTHONKW(try);
PYTHONKW(while);
PYTHONKW(yield);
#undef PYTHONKW
/*
bad names
http://users.ox.ac.uk/~sann1276/python/handbook/node52.html
*/
#define PYTHONBN(x) %namewarn("314:" #x " is a bad name in python") #x
PYTHONBN(Data);
PYTHONBN(Float);
PYTHONBN(Int);
PYTHONBN(Numeric);
PYTHONBN(Oxphys);
PYTHONBN(array);
PYTHONBN(close);
PYTHONBN(float);
PYTHONBN(int);
PYTHONBN(input);
PYTHONBN(open);
PYTHONBN(range);
PYTHONBN(type);
PYTHONBN(write);
PYTHONBN(zeros);
PYTHONBN(True);
PYTHONBN(False);
#undef PYTHONBN
#endif //__python_pythonkw_swg__