Previously -noproxy was required when wrapping some C code

to avoid SWIG generating new_XXX methods.  Now proxy classes are
only ever enabled when wrapping C++ code.


git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@9302 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
Olly Betts 2006-09-20 05:32:22 +00:00
commit 9eb77c5800
2 changed files with 10 additions and 3 deletions

View file

@ -1,6 +1,11 @@
Version 1.3.30 (in progress) Version 1.3.30 (in progress)
============================ ============================
09/20/2006: olly
[php] Previously -noproxy was required when wrapping some C code
to avoid SWIG generating new_XXX methods. Now proxy classes are
only ever enabled when wrapping C++ code.
09/18/2006: mgossage 09/18/2006: mgossage
[ALL] fix on swiginit.swg, has been reported to crash on several test cases [ALL] fix on swiginit.swg, has been reported to crash on several test cases
found and fixed problem in imports under python (mingw) found and fixed problem in imports under python (mingw)

View file

@ -124,7 +124,7 @@ static Hash *shadow_set_vars;
static int native_constructor=0; static int native_constructor=0;
static Hash *zend_types = 0; static Hash *zend_types = 0;
static int shadow = 1; static int shadow = 0; // Default set in PHP::main : 1 for C++; 0 for C.
static bool class_has_ctor = false; static bool class_has_ctor = false;
static String * wrapping_member_constant = NULL; static String * wrapping_member_constant = NULL;
@ -240,12 +240,14 @@ public:
/* ------------------------------------------------------------ /* ------------------------------------------------------------
* main() * main()
* ------------------------------------------------------------ */ * ------------------------------------------------------------ */
virtual void main(int argc, char *argv[]) { virtual void main(int argc, char *argv[]) {
int i; int i;
SWIG_library_directory("php4"); SWIG_library_directory("php4");
SWIG_config_cppext("cpp"); SWIG_config_cppext("cpp");
// Default to generating shadow classes for C++.
shadow = CPlusPlus;
for(i = 1; i < argc; i++) { for(i = 1; i < argc; i++) {
if (argv[i]) { if (argv[i]) {
if(strcmp(argv[i], "-phpfull") == 0) { if(strcmp(argv[i], "-phpfull") == 0) {