Commit graph

21,405 commits

Author SHA1 Message Date
Dmitry D. Chernov
c4ad3480bd Tools: Unify string quoting in the Python sources 2019-07-14 11:15:36 +10:00
Dmitry D. Chernov
c20b6f5b0e Generator: Unify string quoting in generated Python sources 2019-07-14 11:08:17 +10:00
Dmitry D. Chernov
9f79fb5216 Generator: Remove trailing whitespaces in the Python module 2019-07-14 11:06:10 +10:00
William S Fulton
b58995c89e $arg and $input were incorrectly substituted in the argout typemap
when two or more arguments were present.

Closes #1559
2019-06-28 08:09:47 +01:00
William S Fulton
b655d3138b Remove the UnknownExceptionHandler director error handling class
Done in order to be C++17 compliant as it uses std::unexpected_handler
which was removed in C++17. This class was intended for director
exception handling but was never used by SWIG and was never documented.

Closes #1538
2019-06-27 07:40:49 +01:00
William S Fulton
959c228381 Test clang 10.0.1 C++17 - xcode 10.2 2019-06-27 07:40:49 +01:00
William S Fulton
06e5ab8975 Workaround clang 10.0.1 C++17 linker errors in testcases
Fixes:
  Undefined symbols for architecture x86_64: "___cxa_deleted_virtual"
which clang issues when a class deletes a method (seems to be when the
function is not one of the compiler's automatically added special member
functions).
2019-06-27 07:40:49 +01:00
William S Fulton
d6ef118219 std::auto_ptr replacement for testing with C++17 and later
Keep suppressing deprecated warnings for C++11 and C++14
2019-06-27 07:40:49 +01:00
William S Fulton
5c1c69d140 Replace std::unexpected_handler with std::terminate_handler to be c++17 compliant
Closes #1538
2019-06-27 07:40:49 +01:00
William S Fulton
f3357f1f57 Remove use of std::bind2nd which is removed in C++17 2019-06-27 07:40:49 +01:00
William S Fulton
c8cef5c2f2 Fix constexpr-not-const clang warning in testcase
'constexpr' non-static member function will not be implicitly 'const' in C++14; add 'const' to avoid a change in behavior [-Werror,-Wconstexpr-not-const]
2019-06-27 07:40:49 +01:00
William S Fulton
3045ba3532 Warning suppression on testcase using clang 2019-06-27 07:40:49 +01:00
William S Fulton
4301fa548d Remove some legacy cruft from Python proxy class
These methods are no longer used:
_swig_getattr
_swig_setattr
_swig_setattr_nondynamic
2019-06-27 07:40:49 +01:00
William S Fulton
116b6b1028 Remove deprecated calls in Octave testcases
Fixes warning using Octave 5.1:
  warning: findstr is obsolete; use strfind instead
2019-06-27 07:40:49 +01:00
William S Fulton
9bca8ae27e
Merge pull request #1569 from TekuConcept/bug/js-travisci-v4
Fixes Travis CI Build Errors With Node-v4
2019-06-27 07:30:15 +01:00
Chris Walker
99b35b099a Fixes Travis CI Build Errors With Node-v4 2019-06-26 01:10:38 -06:00
William S Fulton
d9cac176f6 Suppress testcase clang warning for auto_ptr deprecation 2019-06-06 19:52:37 +01:00
William S Fulton
7231c2a065 Fix cpp11_rvalue_refrence3 testcase clang warning
cpp11_rvalue_reference3_wrap.cxx:256:38: warning: binding reference member 'member_rvalue_ref_ptr1' to
      a temporary value [-Wdangling-field]
  Thing *&& member_rvalue_ref_ptr1 = 0;
                                     ^
2019-06-06 19:45:24 +01:00
Brad Kotsopoulos
55e835e0ae Java std::vector constructor performance improvement
Reserve before loop of push_back
Refactor li_std_vector testcase

This is a squash merge of #1552
2019-06-06 19:29:11 +01:00
Olly Betts
c864546b4a [Python] Fix implicit_conv tuple handling regression
Introduced in SWIG 4.0.0.  Fixes #1553, reported by Alexandre
Duret-Lutz.
2019-06-03 10:13:58 +12:00
luz.paz
87695dacb1 Misc. documentation and source comment typo fixes
Found via `codespell -q 3 -L uint,od,objext,ba,cmo,bae,ans,struc,fo,clos,goin,upto,thru`
Revert changes in previous commit
2019-05-28 11:41:22 +12:00
William S Fulton
9829bdf5b1 Add Octave detection fixes to changes file 2019-05-24 19:36:36 +01:00
William S Fulton
2cd59b636e Travis Octave testing changes
- Keep testing Octave 4.0 on Xenial, but the Octave headers break the C++11
  tests, so just test C++98.
- Drop Octave 4.2 testing on Trusty.
- Keep Octave 4.4 testing on Trusty - it is the only C++11 Octave testing
  done and is just fast enough to beat the 50 minute limit.
- Add latest Octave version (5.1) testing by using MacOS and brew. It takes
  about 49 minutes to run for C++98 testing.
  Unfortunately it takes longer than the Travis 50 minute limit to test C++11.

I can't find a Xenial or MacOS solution for testing Octave and C++11, so we'll
keep it on Travis for now. Octave is available as a Flatpak's, but Flatpak
doesn't work on Travis as it requires a reboot after installing the flatpak
package.
2019-05-24 19:30:47 +01:00
William S Fulton
6489730892 Fix Octave detection for non-GNU sed on MacOS 2019-05-24 19:30:47 +01:00
Orion Poplawski
ae7c04e204 Adapt OCTAVE_LDFLAGS for Octave 5.1 2019-05-24 19:30:47 +01:00
William S Fulton
e23ae76159 Ruby 1.9 and later testing on Travis xenial
There were (a few) failures using 1.8.7, so document 1.9 and later as
working in SWIG 4.0.
Trusty failure in 2.3.0 was fixed in later versions of Ruby 2.3.x
(expansion of RARRAY_PTR).
2019-05-24 19:30:47 +01:00
Olly Betts
8cae5989b2 Add CHANGES entry for previous commit
Closes https://github.com/swig/swig/pull/1528
2019-05-22 11:38:10 +12:00
Frederik Schubert
b3a3c4f09e Don't add a closing php-tag
This PR removes the closing `?>` PHP tag from generated files. [PSR-2](https://www.php-fig.org/psr/psr-2/) states:

> The closing `?>` tag MUST be omitted from files containing only PHP.

A problem might occur if files with any character after the closing tag are used with `include` or `require`. It might trigger an output and disallow HTTP header manipulation. See the popular [_headers already sent_](https://stackoverflow.com/a/8028987/1847340) debate on SO.
2019-05-22 11:35:08 +12:00
Olly Betts
e87811223c [php] Update docs about undefined constants
PHP 7.2 made these a warning instead of just a notice, and apparently it
will throw an Error in a future version of PHP.
2019-05-22 11:13:55 +12:00
Olly Betts
1dd5d50c99 Fix details of ZEND_MODULE_GLOBALS_ACCESSOR change
This is actually needed when using a ZTS build of any PHP 7.x
release, nothing specific to PHP 7.2 at all.
2019-05-22 11:02:29 +12:00
Zackery Spytz
f042543c6f
Merge pull request #1474 from ZackerySpytz/OCaml-INPUT-OUTPUT-INOUT-primitives
[OCaml] Add missing INPUT, OUTPUT, and INOUT typemaps for primitives
2019-05-13 21:44:02 -06:00
William S Fulton
6a127b75f1 Travis Go testing moved to xenial
The default Go 1.11 version on Travis doesn't work with C++11/C++14:

  gcc_libinit.c:110:3: error: implicit declaration of function ‘nanosleep’

so switch to another gimme version of Go.
2019-05-09 07:41:17 +01:00
William S Fulton
3ccc904b06 Fix php pragmas example include path
Was not working for out of source builds
2019-05-09 07:35:24 +01:00
Zackery Spytz
2f48bec666 Merge remote-tracking branch 'upstream/master' into OCaml-INPUT-OUTPUT-INOUT-primitives 2019-05-08 14:05:02 -06:00
William S Fulton
f06330e720 Move Scilab Travis testing from trusty to xenial 2019-05-07 23:05:53 +01:00
William S Fulton
ed1fabe867 Switch php 7.2 testing to xenial 2019-05-07 19:42:07 +01:00
William S Fulton
ccbc451c7c Disable Travis php 7.2 testing
There is a certificate error on the unsupported Ubuntu Trusty machines.
Php 7.2 is segfaulting on Ubuntu Xenial, so there is work to be done.
2019-05-07 19:38:37 +01:00
William S Fulton
49195c5361 Specify Go version to test with c++11
Default version of Go 1.11.1 on Travis is broken for c++11 testing.

gcc_libinit.c: In function ‘_cgo_try_pthread_create’:
gcc_libinit.c:110:3: error: implicit declaration of function ‘nanosleep’ [-Werror=implicit-function-declaration]
   nanosleep(&ts, nil);
2019-05-04 22:47:19 +01:00
William S Fulton
32c9e2ada8 Travis testing GCC=5 not needed for xenial.
Default compiler is gcc 5 on xenial.
2019-05-04 22:31:48 +01:00
William S Fulton
0cf01afc54 Windows documentation minor improvement 2019-05-04 22:28:35 +01:00
William S Fulton
4539041c50 Travis output optimisation during configure 2019-05-02 21:57:58 +01:00
William S Fulton
00fb2e5629 Travis output optimisation 2019-05-02 21:57:58 +01:00
William S Fulton
25c0397ec4 Travis testing gcc versions
gcc-4.5 has package dependency problems
Add gcc-4.9
2019-05-02 21:57:58 +01:00
William S Fulton
256446d290 Expand Travis testing of core SWIG compilation to include more gcc versions 2019-05-02 21:57:58 +01:00
William S Fulton
48e61eea1d Travis gcc version refactor
Use GCC env variable to hold gcc version to install instead of SWIG_CC
and SWIG_CXX.
2019-05-02 21:57:53 +01:00
William S Fulton
be019a03ce Appveyor testing - make sure language tests are not mistakenly skipped 2019-05-02 19:15:49 +01:00
William S Fulton
78a1515f46 OCaml testing requires camlp4 2019-05-02 07:41:35 +01:00
William S Fulton
dbb5fdda01 Fix php pragmas example
. is not always in the include_path by default
2019-04-30 23:44:41 +01:00
William S Fulton
5d976b0ebe Fix php testcase warning 2019-04-30 23:44:41 +01:00
William S Fulton
9d0cf2ce61 Remove duplicate Travis xenial Octave testing 2019-04-30 23:44:41 +01:00