Olly Betts
28e277f8c5
Fix typo "the the" -> "the"
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12285 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-10-19 06:31:31 +00:00
Joseph Wang
f77ccd81d5
[R] Improve error message for missing argtypes
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12283 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-10-17 09:35:34 +00:00
Joseph Wang
98441fc6ad
[R] Fix failure in overloaded functions which was breaking
...
QuantLib-SWIG
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12282 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-10-17 07:33:58 +00:00
Olly Betts
9eaf5ba1be
[PHP] Allow compilation on non-conforming Microsoft C++ compilers
...
which don't accept: return function_returning_void();
Reported by Frank Vanden Berghen on the SWIG mailing list.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12265 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-10-14 05:13:09 +00:00
William S Fulton
c9ede7e622
Fix unary scope operator (::) (global scope) regression introduced in 2.0.0. The mangled symbol names were incorrect, sometimes resulting in types being incorrectly treated as opaque types.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12264 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-10-13 05:48:59 +00:00
William S Fulton
77a45b2631
visual c++ warning fixes
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12243 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-10-03 16:42:22 +00:00
William S Fulton
3219746776
Apply patch #3066958 from Mikael Johansson to fix default smart pointer handling when the smart pointer contains both a const and non-const operator->.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12240 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-10-03 13:12:00 +00:00
William S Fulton
766ed8db37
Add -pcreversion option to display PCRE version information
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12239 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-10-01 23:52:46 +00:00
Olly Betts
eaada32f26
[Ruby] Avoid segfault when a method node has no parentNode (SF#3034054).
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12237 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-10-01 04:42:29 +00:00
William S Fulton
40e64b14f1
Allocate warnings 700-799 for languages modules. Note 900-999 was and is documented as reserved for user defined warnings.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12230 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-27 05:40:14 +00:00
Olly Betts
5437d71d73
[Python] Improve error message given when a parameter of the wrong
...
type is passed to an overloaded method (SF#3027355).
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12229 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-27 01:16:29 +00:00
William S Fulton
e1ddf0ea3a
Apply SF patch #3075150 - Java directors using static variables in named namespace
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12228 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-25 17:08:13 +00:00
William S Fulton
31af118c41
Move Swig_locator from scanner.c to cscanner.c. Fix file and line error/warning reporting fixes where SWIG macros are used within {} braces (where the preprocessor expands macros), for example macros within %inline {...} and %fragment(...) {...} and nested structs. Basically anything that results ina call to skip_balanced() in the parser/preprocessor.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12227 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-24 22:13:13 +00:00
William S Fulton
1e051820ec
Line/file reporting corrections for warnings: WARN_RUBY_MULTIPLE_INHERITANCE, WARN_TYPE_UNDEFINED_CLASS, WARN_MODULA3_MULTIPLE_INHERITANCE
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12225 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-21 06:07:06 +00:00
William S Fulton
6c094629cb
File and line number corrections for warnings WARN_JAVA_MULTIPLE_INHERITANCE WARN_MODULA3_MULTIPLE_INHERITANCE WARN_CSHARP_MULTIPLE_INHERITANCE and errors 'The javabase typemap for proxy' 'No methodname attribute...' 'No methodmodifiers attribute...' 'The csbase typemap for proxy...'
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12224 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-20 19:11:55 +00:00
William S Fulton
b01277a19b
Various inherited class warning/error line number fixes
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12223 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-18 01:14:21 +00:00
William S Fulton
d1e6643161
Expand the family of debug print functions for displaying DOH types. Provide gdb support for calling these. Document improved debugging experience.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12221 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-15 20:17:11 +00:00
William S Fulton
a202bf9818
Fix undefined behaviour
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12220 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-14 18:52:18 +00:00
William S Fulton
cfcad4ab69
Fix/Workaround unexpected call to Hash_str() when running make director_protected_overloaded.cpptest and director_using.cpptest
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12219 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-14 18:50:04 +00:00
William S Fulton
c0fe7400d2
Fix undefined behaviour with Ruby and autodoc generation
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12218 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-14 06:34:57 +00:00
William S Fulton
efb9090a87
Fix correct line number reporting in errors/warnings when a macro definition ends with '/' and it is not the end of a C comment - swig.swg has some of these macro definitions.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12215 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-11 11:02:18 +00:00
William S Fulton
f82811dbcd
Fix incorrect line number reporting in errors/warnings after parsing macro invocations with parameters given over more than one line.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12214 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-10 23:44:27 +00:00
William S Fulton
122bc852f9
Fix #2149523 - Incorrect line number reporting in errors after parsing macros. Remove extraneous extra line in preprocessed output which would sometimes lead to error/warning messages two lines after the end of the file
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12211 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-10 06:08:45 +00:00
Olly Betts
a25ccbf58b
[PHP] Fix handling of OUTPUT typemaps (Patch from Ryan in SF#3058394).
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12208 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-08 02:40:56 +00:00
William S Fulton
04c3e6b7d3
Fix line numbering for 'Unterminated call invoking macro' error
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12202 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-06 17:30:18 +00:00
William S Fulton
197c8e899d
Fix erroneous line numbers in argument count error messages for macro expansions
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12201 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-03 18:44:01 +00:00
William S Fulton
45601f24b4
Fix line numbers in error and warning messages for preprocessor messages within %inline. Also fixes __LINE__ within %inline
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12200 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-03 17:47:12 +00:00
William S Fulton
a44f83cf05
Fix line numbers in error and warning messages which were accumulately one less than they should have been after parsing each %include/%import - bug introduced in swig-1.3.32. Also fix line numbers in error and warning messages when new line characters appear between the %include / %import statement and the filename.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12199 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-03 06:03:48 +00:00
William S Fulton
aa728ece67
Fix __LINE__ and __FILE__ expansion in macros with no arguments
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12197 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-09-01 21:06:10 +00:00
William S Fulton
31b5f36b74
Fix line number and file name reporting for some macro preprocessor warnings.
...
The line number of the macro argument has been corrected and the line number
of the start of the macro instead of one past the end is used. Some examples:
file.h:11: Error: Illegal macro argument name '..'
file.h:19: Error: Macro 'DUPLICATE' redefined,
file.h:15: Error: previous definition of 'DUPLICATE'.
file.h:25: Error: Variable-length macro argument must be last parameter
file.h:32: Error: Illegal character in macro argument name
file.i:37: Error: Macro 'SIT' expects 2 arguments
Code used for testing:
// file.h
%define SIT(ax,b)
abc(
%enddef
%define MISSING_DOT1(a,
b,
..)
xxx
%enddef
%define MISSING_DOT2(..)
xxx
%enddef
%define DUPLICATE(a,b)
abc
%enddef
%define DUPLICATE(b)
xxx
%enddef
%define VARARGS_WRONG(a,
x,
...,
b)
xxx
%enddef
%define BAD_ARGNAME(
a,
b{c
)
xxx
%enddef
SIT(1)
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12195 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-08-29 23:32:49 +00:00
William S Fulton
5a6443ebcf
Fix some more instances of __LINE__ and __FILE__ numbering
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12194 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-08-29 22:11:03 +00:00
William S Fulton
69af82caa4
Fix __LINE__ and __FILE__ expansion. Mostly this did not work at all.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12192 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-08-26 18:06:02 +00:00
Vadim Zeitlin
024ed6ce2a
Fix bug in applying regex replacement to non-matching strings.
...
We didn't handle pcre_exec() return code properly and so the replacement could
be still done even if there was no match if the replacement part contained
anything else than back-references (in this, the only tested so far, case the
replacement was still done but the result turned out to be empty and the
calling code assumed the regex didn't match).
Do check for PCRE_ERROR_NOMATCH now and also give an error message if another
error unexpectedly occurred.
Add a test case for the bug that was fixed.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12187 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-08-14 14:12:23 +00:00
William S Fulton
af96789c14
Minor comment changes and html changes
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12181 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-07-23 19:34:17 +00:00
Vadim Zeitlin
89a7ab0685
Include the values of configurable options in swig -version.
...
Show the value of important compilation options in swig -version output.
Currently there is just one such option, for PCRE use, but more may be added
in the future.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12176 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-07-22 17:02:55 +00:00
Vadim Zeitlin
587d843521
Remove old experimental rxspencer encoder and rxsmatch function.
...
They are replaced with the new, officially supported PCRE-based regex and
regexmatch.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12175 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-07-22 17:02:35 +00:00
Vadim Zeitlin
70c5bb5a47
Add support for "[not]regexmatch" and "regextarget" to %rename.
...
"regexmatch" and "notregexmatch" can be used with anonymous %renames in the
same way as "match" and "notmatch" while "regextarget" specifies that the
argument of a non-anonymous %rename should be interpreted as a regular
expression.
Document the new functions.
Also add a new unit test for %regex also testing regexmatch &c and provide
test code for C# and Java verifying that it works as intended.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12174 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-07-22 17:02:10 +00:00
Vadim Zeitlin
c4e9043288
Add support for regex encoder for %rename.
...
This allows to write %rename("%(regex:/pattern/subst/)s") to apply a
regex-based replacement to a declaration name.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12170 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-07-22 17:00:37 +00:00
Vadim Zeitlin
ac5ddb0315
Make argument of DohWrite() const.
...
Writing a buffer to a DOH object doesn't modify so it should be const.
This allows the code using const pointers to pass them to DohWrite() without
neither the casts nor gcc warnings.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12167 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-07-22 16:59:29 +00:00
William S Fulton
568607c5ea
Fix wrapping of function pointers and member function pointers when the function returns by reference
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12157 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-07-16 18:45:22 +00:00
William S Fulton
cca92f4188
Fix #3024875 - shared_ptr of classes with non-public destructors. This also fixes the 'unref' feature when used on classes with non-public destructors.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12155 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-07-07 18:19:01 +00:00
Olly Betts
d0d40db326
Use SWIG_PTR rather than literal "_cPtr".
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12149 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-06-25 02:41:27 +00:00
Olly Betts
ae40eff993
The default visibility for methods is public, so don't specify that explicitly
...
to keep the wrapper size down.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12146 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-06-24 14:44:06 +00:00
Olly Betts
9ed2d0165c
Fix comment typo.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12141 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-06-21 03:44:29 +00:00
William S Fulton
95a3eb5a7d
code style: fix inconsistent NULL pointer comparisons
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12137 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-06-17 23:49:12 +00:00
William S Fulton
07ca3eb9f8
remove unnecessary NULL check before calling Delete
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12136 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-06-17 23:03:18 +00:00
Ian Lance Taylor
2970f53c21
Remove the -rename option in the Go language support. Do a much
...
better job of checking for name conflicts. Ignore conflicting names
with a warning. Adjust the testsuite accordingly.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12135 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-06-17 18:59:26 +00:00
Ian Lance Taylor
e7fde8c432
Set wrap:name attribute when generating a call to a method in a base class.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12132 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-06-16 15:43:05 +00:00
Ian Lance Taylor
814eaab177
Remove comments about compiling file with gcc.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12130 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-06-15 20:15:11 +00:00
Ian Lance Taylor
da5e02f81c
Rename "go" typemap to "gotype".
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12129 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2010-06-15 19:40:34 +00:00