Eric Sunshine patch - Mods to work on NextStep

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@5674 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
William S Fulton 2004-01-22 22:42:18 +00:00
parent 25f7d19348
commit 11561b2499
20 changed files with 70 additions and 88 deletions

View File

@ -1030,7 +1030,9 @@ int DohStrncmp(const DOHString_or_char *s1, const DOHString_or_char *s2, int n)
}
char *DohStrstr(const DOHString_or_char *s1, const DOHString_or_char *s2) {
return strstr(Char(s1),Char(s2));
char* p1 = Char(s1);
char* p2 = Char(s2);
return p2 == 0 || *p2 == '\0' ? p1 : strstr(p1,p2);
}
char *DohStrchr(const DOHString_or_char *s1, int ch) {

View File

@ -12,9 +12,6 @@
char cvsroot_browser_cxx[] = "$Header$";
#ifndef MACSWIG
#include "swigconfig.h"
#endif
#include "swigmod.h"
#ifdef SWIG_SWILL

View File

@ -23,10 +23,6 @@ char cvsroot_chicken_cxx[] = "$Header$";
#include "swigmod.h"
#ifndef MACSWIG
#include "swigconfig.h"
#endif
#include <ctype.h>
static const char *chicken_usage = (char*)"\
@ -134,10 +130,12 @@ protected:
* swig_chicken() - Instantiate module
* ----------------------------------------------------------------------- */
extern "C" Language *
swig_chicken(void) {
static Language * new_swig_chicken() {
return new CHICKEN();
}
extern "C" Language * swig_chicken(void) {
return new_swig_chicken();
}
void
CHICKEN::main(int argc, char *argv[])

View File

@ -14,9 +14,6 @@ char cvsroot_csharp_cxx[] = "$Header$";
#include <limits.h> // for INT_MAX
#include "swigmod.h"
#ifndef MACSWIG
#include "swigconfig.h"
#endif
#include <ctype.h>
class CSHARP : public Language {
@ -2021,10 +2018,12 @@ class CSHARP : public Language {
* swig_csharp() - Instantiate module
* ----------------------------------------------------------------------------- */
extern "C" Language *
swig_csharp(void) {
static Language * new_swig_csharp() {
return new CSHARP();
}
extern "C" Language * swig_csharp(void) {
return new_swig_csharp();
}
/* -----------------------------------------------------------------------------
* Static member variables

View File

@ -30,9 +30,6 @@ char cvsroot_guile_cxx[] = "$Header$";
#include "swigmod.h"
#ifndef MACSWIG
#include "swigconfig.h"
#endif
#include <ctype.h>
// Note string broken in half for compilers that can't handle long strings
@ -1766,7 +1763,9 @@ public:
* swig_guile() - Instantiate module
* ----------------------------------------------------------------------------- */
extern "C" Language *
swig_guile(void) {
static Language * new_swig_guile() {
return new GUILE();
}
extern "C" Language * swig_guile(void) {
return new_swig_guile();
}

View File

@ -14,9 +14,6 @@ char cvsroot_java_cxx[] = "$Header$";
#include <limits.h> // for INT_MAX
#include "swigmod.h"
#ifndef MACSWIG
#include "swigconfig.h"
#endif
#include <ctype.h>
/* Hash type used for JNI upcall data */
@ -3281,10 +3278,12 @@ class JAVA : public Language {
* swig_java() - Instantiate module
* ----------------------------------------------------------------------------- */
extern "C" Language *
swig_java(void) {
static Language * new_swig_java() {
return new JAVA();
}
extern "C" Language * swig_java(void) {
return new_swig_java();
}
/* -----------------------------------------------------------------------------
* Static member variables

View File

@ -20,9 +20,6 @@ char cvsroot_main_cxx[] = "$Header$";
#endif
#include "swigmod.h"
#ifndef MACSWIG
#include "swigconfig.h"
#endif
#include "swigwarn.h"
#include "cparse.h"

View File

@ -25,10 +25,6 @@ char cvsroot_mzscheme_cxx[] = "$Header$";
#include "swigmod.h"
#ifndef MACSWIG
#include "swigconfig.h"
#endif
#include <ctype.h>
static const char *usage = (char*)"\
@ -690,9 +686,11 @@ public:
* swig_mzscheme() - Instantiate module
* ----------------------------------------------------------------------------- */
extern "C" Language *
swig_mzscheme(void) {
static Language * new_swig_mzscheme() {
return new MZSCHEME();
}
extern "C" Language * swig_mzscheme(void) {
return new_swig_mzscheme();
}

View File

@ -20,10 +20,6 @@ char cvsroot_ocaml_cxx[] = "$Header$";
#include "swigmod.h"
#ifndef MACSWIG
#include "swigconfig.h"
#endif
#include <ctype.h>
static const char *usage = (char*)
@ -1898,8 +1894,10 @@ public:
* swig_ocaml() - Instantiate module
* ------------------------------------------------------------------------- */
extern "C" Language *
swig_ocaml(void) {
static Language * new_swig_ocaml() {
return new OCAML();
}
extern "C" Language * swig_ocaml(void) {
return new_swig_ocaml();
}

View File

@ -17,10 +17,6 @@ char cvsroot_perl5_cxx[] = "$Header$";
#include "swigmod.h"
#ifndef MACSWIG
#include "swigconfig.h"
#endif
static const char *usage = (char*)"\
Perl5 Options (available with -perl5)\n\
-ldflags - Print runtime libraries to link with\n\
@ -1436,7 +1432,9 @@ public:
* swig_perl5() - Instantiate module
* ----------------------------------------------------------------------------- */
extern "C" Language *
swig_perl5(void) {
static Language * new_swig_perl5() {
return new PERL5();
}
extern "C" Language * swig_perl5(void) {
return new_swig_perl5();
}

View File

@ -17,10 +17,6 @@ char cvsroot_php4_cxx[] = "$Header$";
#include "swigmod.h"
#ifndef MACSWIG
#include "swigconfig.h"
#endif
#include <ctype.h>
@ -894,7 +890,7 @@ public:
*/
void create_command(char *cname, char *iname) {
// char *lower_cname = strdup(cname);
// char *lower_cname = Swig_copy_string(cname);
// char *c;
// for(c = lower_cname; *c != '\0'; c++) {
@ -2115,8 +2111,7 @@ void typetrace(SwigType *ty, String *mangled, String *clientdata) {
if (r_prevtracefunc) (*r_prevtracefunc)(ty, mangled, (String *) clientdata);
}
extern "C" Language *
swig_php(void) {
static Language * new_swig_php() {
maininstance=new PHP4();
if (! r_prevtracefunc) {
r_prevtracefunc=SwigType_remember_trace(typetrace);
@ -2126,4 +2121,6 @@ swig_php(void) {
}
return maininstance;
}
extern "C" Language * swig_php(void) {
return new_swig_php();
}

View File

@ -21,9 +21,6 @@
char cvsroot_pike_cxx[] = "$Header$";
#include "swigmod.h"
#ifndef MACSWIG
#include "swigconfig.h"
#endif
#include <ctype.h> // for isalnum()
@ -880,7 +877,9 @@ public:
* swig_pike() - Instantiate module
* ----------------------------------------------------------------------------- */
extern "C" Language *
swig_pike(void) {
static Language * new_swig_pike() {
return new PIKE();
}
extern "C" Language * swig_pike(void) {
return new_swig_pike();
}

View File

@ -13,10 +13,6 @@ char cvsroot_python_cxx[] = "$Header$";
#include "swigmod.h"
#ifndef MACSWIG
#include "swigconfig.h"
#endif
#include <ctype.h>
#define PYSHADOW_MEMBER 0x2
@ -2187,7 +2183,9 @@ public:
* swig_python() - Instantiate module
* ----------------------------------------------------------------------------- */
extern "C" Language *
swig_python(void) {
static Language * new_swig_python() {
return new PYTHON();
}
extern "C" Language * swig_python(void) {
return new_swig_python();
}

View File

@ -15,10 +15,6 @@ char cvsroot_ruby_cxx[] = "$Header$";
#include "swigmod.h"
#define SWIG_PROTECTED_TARGET_METHODS 1
#ifndef MACSWIG
#include "swigconfig.h"
#endif
#include <ctype.h>
#include <string.h>
#include <limits.h> /* for INT_MAX */
@ -2357,10 +2353,12 @@ public:
* swig_ruby() - Instantiate module
* ----------------------------------------------------------------------------- */
extern "C" Language *
swig_ruby(void) {
static Language * new_swig_ruby() {
return new RUBY();
}
extern "C" Language * swig_ruby(void) {
return new_swig_ruby();
}
/*

View File

@ -406,7 +406,9 @@ public:
};
extern "C" Language *
swig_sexp( void ) {
static Language * new_swig_sexp() {
return new Sexp();
}
extern "C" Language * swig_sexp( void ) {
return new_swig_sexp();
}

View File

@ -22,10 +22,6 @@
char cvsroot_swigmain_cxx[] = "$Header$";
#ifndef MACSWIG
#include "swigconfig.h"
#endif
#include "swigmod.h"
/* Module factories. These functions are used to instantiate

View File

@ -24,10 +24,6 @@ char cvsroot_tcl8_cxx[] = "$Header$";
#include "swigmod.h"
#ifndef MACSWIG
#include "swigconfig.h"
#endif
static const char *usage = (char*)"\
Tcl 8 Options (available with -tcl)\n\
-itcl - Enable ITcl support\n\
@ -1220,10 +1216,12 @@ public:
* swig_tcl() - Instantiate module
* ---------------------------------------------------------------------- */
extern "C" Language *
swig_tcl(void) {
static Language * new_swig_tcl() {
return new TCL8();
}
extern "C" Language * swig_tcl(void) {
return new_swig_tcl();
}

View File

@ -332,7 +332,9 @@ public:
};
extern "C" Language *
swig_xml( void ) {
static Language * new_swig_xml() {
return new XML();
}
extern "C" Language * swig_xml( void ) {
return new_swig_xml();
}

View File

@ -12,9 +12,6 @@
char cvsroot_misc_c[] = "$Header$";
#include "swig.h"
#ifndef MACSWIG
#include "swigconfig.h"
#endif
#include <ctype.h>
/* -----------------------------------------------------------------------------

View File

@ -24,6 +24,16 @@
extern "C" {
#endif
#ifndef MACSWIG
#include "swigconfig.h"
#endif
#if defined(__cplusplus) && !defined(HAVE_BOOL)
typedef int bool;
#define true ((bool)1)
#define false ((bool)0)
#endif
#include "doh.h"
/* Status codes */