William S Fulton
16481c999e
Bug #3563647 - PyInt_FromSize_t unavailable prior to Python 2.5 for unsigned int types
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13953 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-12-09 20:49:52 +00:00
William S Fulton
5e507b82f1
Apply patch #3571029 which adds missing director support for const unsigned long long &.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13952 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-12-09 20:49:28 +00:00
William S Fulton
7375731431
Perl - Fix C++ comment in C wrappers.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13951 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-12-09 17:47:12 +00:00
Karl Wette
e60ae2d81d
octave: Simplified module loading.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13941 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-11-28 20:22:56 +00:00
Vadim Zeitlin
0ca11c8b6f
Fix overflow with parameters > LONG_MAX with Python 3.
...
The typemap incorrectly called PyInt_AsLong() if PyInt_Check() passed, but
this check is the same as PyLong_Check() for Python 3 and so the correct
PyLong_AsUnsignedLong() function was never called. As a consequence, passing
any value greater than LONG_MAX (e.g. 0x87654321 on 32 bit architectures) to a
function taking unsigned int, unsigned long or size_t parameter failed with an
overflow error being generated.
Fix this by simply disabling the part of the code dealing with PyInts for
Python 3 as there is no distinction between PyInt and PyLong there any more.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13877 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-11-09 17:57:42 +00:00
Ian Lance Taylor
ab7da898ef
Define uintgo for the benefit of Go .swig files.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13876 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-10-31 03:41:10 +00:00
Ian Lance Taylor
786d883d45
Fix Go support for enums to work correctly when Go int type is 64 bits.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13875 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-10-30 23:38:57 +00:00
Ian Lance Taylor
a42882dcee
Adjust for change in the size of the Go type int. Until some time in
...
the future, require a -intgosize option when invoking SWIG. Otherwise
there is no reliable way for us to know the size of int, and we need
to know.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13864 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-10-05 04:58:00 +00:00
Ian Lance Taylor
5e30ec58e8
Adjust typemaps.i for change in handling of reference to slice.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13856 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-10-02 14:53:13 +00:00
William S Fulton
d1bc8b5b21
Add caveat emptor for peek method in Java directors
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13838 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-09-13 19:18:25 +00:00
William S Fulton
863c25f9b8
Possibly incorrect DeleteGlobalRef call on a weak global reference in Java directors - patch from Marvin Greenberg
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13837 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-09-13 19:05:25 +00:00
William S Fulton
b38722e8ee
Apply patch for Java to fix direct use of a weak global reference in directors sometimes causing seg faults especially on Android.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13834 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-09-13 19:02:02 +00:00
William S Fulton
593c708a78
Fix (char *STRING, size_t LENGTH) typemaps to accept NULL string
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13736 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-09-07 06:07:20 +00:00
William S Fulton
2c74c90430
Fix for gcc warning -Wunused-value without triggering -Wunused-parameter
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13735 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-09-07 06:06:00 +00:00
William S Fulton
d496352805
Move contributors to COPYRIGHT file.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13734 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-09-07 06:03:20 +00:00
Joseph Wang
33bb317b61
make ExternalReference slot ref to contain reference
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13721 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-08-26 03:35:04 +00:00
William S Fulton
be1c4d2e68
Revert r13601 as it breaks older versions of R
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13713 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-08-20 21:20:19 +00:00
William S Fulton
11323af905
A working fix to silence unused warnings - fixes r13621
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13637 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-08-16 22:35:36 +00:00
William S Fulton
a0d15a7e03
Better fix than r6987 to silence warning
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13621 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-08-15 23:36:28 +00:00
William S Fulton
c20cacad87
Add some missing STL container typedefs for Perl
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13620 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-08-15 23:04:26 +00:00
William S Fulton
049035ff3e
Add discard and add methods to std::set and std::multiset wrappers so that pyabc.i can be used ensuring MutableSet is a valid abstract base class
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13619 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-08-15 22:36:15 +00:00
William S Fulton
81b755dadc
Better error handling in SWIG_Python_NewShadowInstance and SWIG_Python_NewPointerObj to fix seg fault as mentioned on swig-devel mailing list email thread - 'Fix python3 abc set'
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13618 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-08-15 22:35:24 +00:00
William S Fulton
68862691e6
Fix #3541744 - Missing PyInt_FromSize_t calls for Python 3
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13608 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-08-15 07:48:57 +00:00
Joseph Wang
fad95da7f5
change R components so that pointers are visible through ref
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13601 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-08-12 15:21:39 +00:00
William S Fulton
3b8bc08be7
Suppress -Werror=unused-but-set-variable gcc warning in Python wrappers
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13571 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-08-08 22:24:46 +00:00
Joseph Wang
c8b8d4f50d
add pair to stl.i
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13562 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-08-08 14:13:37 +00:00
Sylvestre Ledru
7dac1bc524
Fix somes typos
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13559 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-08-08 09:19:26 +00:00
William S Fulton
4305a3cef9
#3545877 - Don't undefine bool if defined by C99 stdbool.h - problem using Perl 5.16 and later.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13513 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-08-05 10:15:08 +00:00
William S Fulton
196f9b31ed
Remove unused temp variable in C# intrusive_ptr wrappers
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13510 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-08-04 23:20:07 +00:00
Karl Wette
ae0c4d37b9
octave: improved segfault-on-exit prevention hack
...
- Now simply set exit function pointer "octave_exit" to _Exit.
This correctly preserves exit status when error() is called.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13336 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-07-20 07:31:32 +00:00
Karl Wette
d1ae77bdc2
octave: use _Exit instead of _exit
...
- _exit is a POSIX function (unistd.h), whereas _Exit is in C99 (stdlib.h)
and is therefore more likely to be supported by C++ compilers (cstdlib)
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13318 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-07-12 17:53:02 +00:00
William S Fulton
e4a3a004ae
Move contributor names to where they belong
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13160 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-06-11 18:05:56 +00:00
Joseph Wang
cf16f43e51
add std_vector items`
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13159 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-06-10 13:54:27 +00:00
Ian Lance Taylor
5a19113432
Import unsafe in generated Go code, so that pointers stored as type
...
uintptr do not get garbage collected.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13153 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-06-05 20:54:08 +00:00
Ian Lance Taylor
9a6dc5ac40
Fix typo in name of SwigDoCgocallDone for GCC < 4.7.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13151 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-06-05 13:32:28 +00:00
Ian Lance Taylor
7ec208da05
Fix Go support to use appropriate interface for entering and leaving
...
C/C++ code, depending on GCC version.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13146 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-06-04 05:37:10 +00:00
Olly Betts
5b2f38101f
Fix comment typos in Lua typemaps
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13132 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-28 18:32:24 +00:00
William S Fulton
e62dc28f16
Clean up Lua std::string typemaps
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13121 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-26 07:07:00 +00:00
William S Fulton
12a9671440
std::string typemap modifications so they can be used with %apply for other string classes
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13120 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-26 06:33:49 +00:00
William S Fulton
49b6c39d98
Lua fix for -external-runtime
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13119 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-24 23:05:07 +00:00
Karl Wette
f76d63419f
[octave] Declare these functions only if directors are used
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13108 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-23 09:32:51 +00:00
Karl Wette
f8135379a1
[octave] Make sure SWIG_global_name is a std::string for comparison
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13107 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-23 09:32:38 +00:00
Stefan Zager
00328ccdb3
python: disambiguate SWIG_From_unsigned_SS_int and SWIG_From_unsigned_SS_long.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13106 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-23 04:05:11 +00:00
William S Fulton
142f1e72bb
Fix some language's std::map wrappers to recognise difference_type, size_type, key_type and mapped_type.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13092 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-15 19:51:06 +00:00
Karl Wette
bc2a78fbab
New Octave module loading behaviour
...
- Use call syntax instead of cmdline to choose global/noglobal load:
global: 'example;', noglobal: 'example = example;'
- All functions loaded with Octave 'autoload' command; correctly
loads .oct module and prevents segfault in Octave 3.0.5
- Functions no longer installed as global variables as well,
so global operator dispatch now only looks for functions
- Octave at-exit function created from string, not function,
so no dependence on loaded .oct files at cleanup time
- C at-exit function now immediately exits Octave (with correct
status) to prevent seg-fault due to dodgy memory cleanup
in some Octave versions
- Documentation string for module loading function
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13088 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-14 09:24:15 +00:00
Karl Wette
4f11aaa849
Declare Octave public wrapping functions with DEFUNX_DLD
...
- New helper function Octave_begin_function writes function declaration
and installer function definition using SWIG_DEFUN macro, which in
turn uses Octave DEFUNX_DLD macro
- Can now use Octave's dynamic module loader to load functions safely
- Link documentation of public wrapping functions through DEFUNX_DLD
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13087 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-14 09:24:00 +00:00
Karl Wette
bf0fe83462
New functions for handling Octave global variables
...
- Creates a copy of the variable to be assigned to the
symbol table, so it can be safely deallocated on exit
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13086 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-14 09:23:45 +00:00
Karl Wette
a0dbe43c73
Move Octave SWIG runtime functions to Lib/octave/octruntime.swg
...
- Add documentation strings for runtime functions
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13085 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-14 09:23:33 +00:00
Karl Wette
de49578c31
Move Octave director-related code into Lib/octave/director.swg
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13084 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-14 09:23:20 +00:00
Olly Betts
d96db667f7
[PHP] Avoid using zend_error_noreturn() as it doesn't work with all
...
builds of PHP (SF bug #3166423 ). Instead we now wrap it in a
SWIG_FAIL() function which we annotate as "noreturn" for GCC to
avoids warnings. This also reduces the size of the compiled
wrapper (e.g. the stripped size is 6% for Xapian's PHP bindings).
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13077 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-12 13:26:16 +00:00