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

@ -3,28 +3,29 @@
/* Warnings for certain CHICKEN keywords. From Section 7.1.1 of /* Warnings for certain CHICKEN keywords. From Section 7.1.1 of
Revised^5 Report on the Algorithmic Language Scheme */ Revised^5 Report on the Algorithmic Language Scheme */
#define CHICKW(x) %namewarn("314:" #x " is a R^5RS syntatic keyword") #x #define CHICKENKW(x) %namewarn("314:" #x " is a R^5RS syntatic keyword") #x
CHICKW(else); CHICKENKW(else);
CHICKW(=>); CHICKENKW(=>);
CHICKW(define); CHICKENKW(define);
CHICKW(unquote); CHICKENKW(unquote);
CHICKW(unquote-splicing); CHICKENKW(unquote-splicing);
CHICKW(quote); CHICKENKW(quote);
CHICKW(lambda); CHICKENKW(lambda);
CHICKW(if); CHICKENKW(if);
CHICKW(set!); CHICKENKW(set!);
CHICKW(begin); CHICKENKW(begin);
CHICKW(cond); CHICKENKW(cond);
CHICKW(and); CHICKENKW(and);
CHICKW(or); CHICKENKW(or);
CHICKW(case); CHICKENKW(case);
CHICKW(let); CHICKENKW(let);
CHICKW(let*); CHICKENKW(let*);
CHICKW(letrec); CHICKENKW(letrec);
CHICKW(do); CHICKENKW(do);
CHICKW(delay); CHICKENKW(delay);
CHICKW(quasiquote); CHICKENKW(quasiquote);
#undef CHICKENKW
#endif //__chicken_chickenkw_swg__ #endif //__chicken_chickenkw_swg__

View file

@ -467,3 +467,6 @@ using System.Runtime.InteropServices;
%apply long { size_t }; %apply long { size_t };
/* csharp keywords */
/* please test and activate */
//%include "csharpkw.swg"

View file

@ -87,7 +87,10 @@ CSHARPKW(void);
CSHARPKW(volatile); CSHARPKW(volatile);
CSHARPKW(while); CSHARPKW(while);
/* swig seems to managing this one right */ /* swig seems to managing this one right */
// CSHARPKW(string); // CSHARPKW(string);
#undef CSHARPKW
#endif //__csharp_csharpkw_swg__ #endif //__csharp_csharpkw_swg__

View file

@ -61,7 +61,10 @@ JAVAKW(while);
/* others bad names */ /* others bad names */
// Not really sure about this, but sometimes it produce problems /* Not really sure about this, but sometimes it produce problems */
// %namewarn("314:clone is a java reserved method name") *::clone; // %namewarn("314:clone is a java reserved method name") *::clone;
#undef JAVAKW
#endif //__java_javakw_swg__ #endif //__java_javakw_swg__

View file

@ -86,4 +86,7 @@ PHPKW(xor);
// This is conflicting with _std_deque.i!. // This is conflicting with _std_deque.i!.
PHPKW(empty); PHPKW(empty);
#undef PHPKW
#endif //__php_phpkw_swg__ #endif //__php_phpkw_swg__

View file

@ -51,4 +51,6 @@ PIKEKW(while);
// Swig manages this one right // Swig manages this one right
// PIKEKW(string); // PIKEKW(string);
#undef PIKEKW
#endif //__pike_pikekw_swg__ #endif //__pike_pikekw_swg__

View file

@ -2,36 +2,67 @@
#define __python_pythonkw_swg__ #define __python_pythonkw_swg__
/* Warnings for Python keywords */ /* 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); PYTHONKW(and);
PYKW(assert); PYTHONKW(assert);
PYKW(break); PYTHONKW(break);
PYKW(class); PYTHONKW(class);
PYKW(continue); PYTHONKW(continue);
PYKW(def); PYTHONKW(def);
PYKW(del); PYTHONKW(del);
PYKW(elif); PYTHONKW(elif);
PYKW(else); PYTHONKW(else);
PYKW(except); PYTHONKW(except);
PYKW(exec); PYTHONKW(exec);
PYKW(finally); PYTHONKW(finally);
PYKW(for); PYTHONKW(for);
PYKW(from); PYTHONKW(from);
PYKW(global); PYTHONKW(global);
PYKW(if); PYTHONKW(if);
PYKW(import); PYTHONKW(import);
PYKW(in); PYTHONKW(in);
PYKW(is); PYTHONKW(is);
PYKW(lambda); PYTHONKW(lambda);
PYKW(not); PYTHONKW(not);
PYKW(or); PYTHONKW(or);
PYKW(pass); PYTHONKW(pass);
PYKW(print); PYTHONKW(print);
PYKW(raise); PYTHONKW(raise);
PYKW(return); PYTHONKW(return);
PYKW(try); PYTHONKW(try);
PYKW(while); 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__ #endif //__python_pythonkw_swg__

View file

@ -53,4 +53,6 @@ RUBYKW(until);
/* swig doesn't like this one */ /* swig doesn't like this one */
// RUBYKW(defined); // RUBYKW(defined);
#undef RUBYKW
#endif //__ruby_rubykw_swg__ #endif //__ruby_rubykw_swg__