Commit graph

533 commits

Author SHA1 Message Date
William S Fulton
3f03858862 minor formatting
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@11044 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2009-01-08 23:29:33 +00:00
William S Fulton
e2679a6fd3 correct return type for PyUnicode_GetSize
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@11041 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2009-01-08 19:20:51 +00:00
Haoyu Bai
8f84447860 Commited SF#2158938: change all SWIG symbols start with Py to a new name.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10961 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-12-03 18:43:44 +00:00
William S Fulton
93f0390322 UTL - Fix some incorrect acceptance of types in the STL, eg a double * element passed into a vector<int *> constructor would be accepted, but the ensuing behaviour was undefined. Now the type conversion correctly raises an exception
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10958 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-11-28 23:35:46 +00:00
William S Fulton
7ec3c4ae81 minor typo and formatting improvements
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10868 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-09-18 20:16:50 +00:00
William S Fulton
6588eb61f4 pointer display correction
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10867 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-09-18 20:16:03 +00:00
Haoyu Bai
3d8ddfc442 Merged the Python 3.0 support branch. The merging progress is not so smooth, so hope this commit won't make anything broken.
This is the (incomplemete) log produced by svnmerge.py:

Merged revisions 10405-10409,10420-10422,10426,10438,10445,10451,10454-10465,10467,10473-10475,10485,10488-10489,10493-10495,10497,10509-10510,10513-10514,10517,10520,10525,10528-10529,10533-10535,10554-10557,10570,10573,10593,10614,10666-10669,10673,10678,10687,10690,10704-10706,10731,10744,10750-10752,10755,10759,10770,10775-10776,10813,10819 via svnmerge from 
https://swig.svn.sourceforge.net/svnroot/swig/branches/gsoc2008-bhy



git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10834 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-09-11 17:18:07 +00:00
Richard Boulton
761ef2b98f [Python] Commit patch #2089149: Director exception handling mangles
returned exception.  Exceptions raised by Python code in directors
are now passed through to the caller without change.  Also, remove
the ": " prefix which used to be added to other director exceptions
(eg, those due to incorrect return types).


git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10827 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-09-10 10:08:21 +00:00
William S Fulton
2cafaf9d43 Fix #1988296 - Multiple module director linking issue
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10809 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-09-02 23:01:37 +00:00
William S Fulton
1213c5640a Fix unused parameter warnings in python when using gcc's -W -Wall options
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10547 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-06-21 22:25:36 +00:00
William S Fulton
9c323f4a70 Add R keyword support. Rename keywords for successful compilation of Java and C# code. More consistent keyword warnings across the different languages.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10530 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-06-19 20:02:13 +00:00
Haoyu Bai
1dfb0d7fad Fixed SF #1971977: typo in pycontainer.swg (related to -extranative option)
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10504 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-05-28 17:27:48 +00:00
Olly Betts
20954f9bdc Fix comment and documentation typos
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10446 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-05-14 14:53:10 +00:00
William S Fulton
da8791792b STL fixes when using %import rather than %include and the Solaris Workshop compiler
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10424 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-05-07 21:33:19 +00:00
Olly Betts
85f02c4ba4 [Python] Fix generated code for IBM's C++ compiler on AIX (patch
from Goeran Uddeborg in SF#1928048).


git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10387 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-04-24 12:26:29 +00:00
William S Fulton
69d6ce4f33 Fix shared_ptr typemaps for use with %pythonnondynamic
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10344 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-04-04 23:29:59 +00:00
William S Fulton
8c24e2ca74 Fix shared_ptr typemaps where the pointer type is a templated type with with more than one parameter.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10327 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-03-27 20:29:01 +00:00
Olly Betts
b2375fd6e6 [Python] Apply GCC 4.3 warnings patch from Philipp Thomas (SF#1925122).
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10321 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-03-26 08:52:57 +00:00
William S Fulton
a1100e9964 Thread safety patch for Python STL iterators from Abhinandan Jain
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10317 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-03-21 23:11:24 +00:00
William S Fulton
b697a8fc75 operator bool mapping to __nonzero__ as per Josh Cherry suggestion
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10315 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-03-20 22:01:39 +00:00
William S Fulton
77cd446a53 remove debugging info from shared_ptr typemaps
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10302 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-03-12 16:48:37 +00:00
William S Fulton
1a560e3866 global variables test and shared_ptr varin/varout typemaps
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10285 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-02-29 23:23:35 +00:00
William S Fulton
9b7042280c Add member variable support for shared_ptr
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10260 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-02-14 22:53:11 +00:00
William S Fulton
f7deb81de1 Fix C compilation
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10253 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-02-13 23:18:39 +00:00
William S Fulton
444f643c4e Add shared_ptr typecheck typemaps for Python and add overloaded method tests for shared_ptr
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10251 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-02-13 23:10:58 +00:00
William S Fulton
c62cb6180e always pass in non-null value for newmemory parameter in the casting function
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10243 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-02-10 21:34:56 +00:00
William S Fulton
3d1356dead Complete the Python support for shared_ptr mainly for derived classes. This includes the smartptr feature for overriding the class registration function and shared_ptr typemaps
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10237 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-02-09 12:26:21 +00:00
William S Fulton
f39242fa92 Complete the Python support for shared_ptr mainly for derived classes. This includes the smartptr feature for overriding the class registration function and shared_ptr typemaps
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10236 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-02-09 12:25:41 +00:00
Olly Betts
9a74c3a918 [Python] Fix format string bug (SF#1882220).
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10228 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-02-01 16:45:11 +00:00
William S Fulton
76229dbab8 Restore containers accepting NULL pointers when used in overloaded methods - problem reported by Josh Cherry
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10217 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-01-22 23:33:59 +00:00
William S Fulton
cb9d191276 Remove conversion from one STL container to another
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10214 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-01-21 21:59:02 +00:00
William S Fulton
4c335c9422 fix possible null pointer deref - bug 1863647
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10204 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-01-12 23:06:06 +00:00
William S Fulton
521059242c gcc-4.2 warning fixes
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10186 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2007-12-09 22:27:38 +00:00
William S Fulton
c66c3dd632 Fix confusion of filenaming in comment
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10153 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2007-11-19 21:32:01 +00:00
Olly Betts
bc9c671d84 [Python] Don't pass Py_ssize_t for a %d printf-like format as
that's undefined behaviour when sizeof(Py_ssize_t) != sizeof(int).


git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10145 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2007-11-16 16:05:10 +00:00
William S Fulton
79eea19382 string handling mods to keep gcc-4.2 happy
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10088 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2007-11-04 20:35:59 +00:00
William S Fulton
c8e1d09cff Warning fixes
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10041 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2007-10-25 22:36:23 +00:00
William S Fulton
e49c07014d Correct usage of Py_ssize_t
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10040 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2007-10-25 22:33:20 +00:00
William S Fulton
9c65c6b044 Remove cvs $Header$
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10004 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2007-10-17 21:43:55 +00:00
Olly Betts
c166ffc10d Release our mutex rather than free-ing it, since we want it around to reuse.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@9994 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2007-10-16 23:01:23 +00:00
Olly Betts
8178898960 [python] Simpler code for SWIG_AsVal_bool() which fixes a "strict
aliasing" warning from GCC - patch from SF#1724581 by Andrew
Baumann.


git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@9938 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2007-09-17 23:52:16 +00:00
Olly Betts
38829f2ce0 [Python]
Fix "missing initialiser" warning when compiling generated C/C++
wrapper code with Python 2.5 with warnings enabled (patch from
bug#1727668 from Luke Moore).


git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@9842 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2007-05-31 02:20:45 +00:00
Olly Betts
4aaf48d650 swig -python -threads now generates C/C++ code which uses Python's
own threading abstraction (from pythread.h) rather than OS specific
code.  The old code failed to compile on MS Windows.  (See SF patch
tracker #1710341).


git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@9806 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2007-05-12 13:55:19 +00:00
Gonzalo Garramuno
4ead0ce7b2 Removed python crap from std/std_common.i
and moved it to python/std_common.i
Consolidated ruby code to use std/std_common.i
Added missing include to rubystdfunctors.swg



git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@9781 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2007-05-06 06:28:23 +00:00
Gonzalo Garramuno
1992714551 Fixed a problem of an incorrect check-in with
fprintf line.



git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@9749 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2007-05-02 05:22:44 +00:00
William S Fulton
a4c0660859 separate Python error message from the SWIG supplied one
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@9727 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2007-04-30 20:42:01 +00:00
Gonzalo Garramuno
806d9040c5 Updated CHANGES.current.
Fixed problems with insert() and unshift() functions in std::vector for ruby.
Updated Ruby documentation.
Improved swig_assert.rb.
Added "second" singleton to std_pair in ruby.
Modified two tests to follow the new STL stuff.



git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@9721 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2007-04-30 09:45:10 +00:00
William S Fulton
8c989f8fe3 better director error message formatting
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@9686 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2007-04-20 22:00:21 +00:00
Olly Betts
e19603cb51 Improve how/when we define Py_ssize_t to match the way the python developers
recommend, so that it works if the user includes headers from something like
numpy which also defines Py_ssize_t.


git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@9546 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2006-11-12 01:33:58 +00:00
William S Fulton
4b72de7d62 contents moved to director.swg
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@9367 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2006-09-26 21:16:45 +00:00