William S Fulton
220a735ec5
Update php test
2018-10-09 19:37:07 +01:00
luz.paz
60dfa31a67
Misc. typos
...
found via `codespell` and `grep`
2018-05-17 10:04:23 -04:00
William S Fulton
50cb18087d
test-suite fixes (2) for compilers that don't support varargs
...
Split director_exception testcase into two so that testing throw(),
with no arguments, that is nothrows, can be tested separately to throw()
taking arguments. [The throw keyword needs to be removed for C++
compilation in C++11 and later when it was deprecated.]
2018-05-06 09:46:37 +01:00
William S Fulton
08210236ef
Fix newobject3 testcase
...
Fixes Octave problem which has a template called product.
2017-10-10 08:05:21 +01:00
Olly Betts
0ca47dd7cc
CHANGES.current entry and regression test for previous commit
2017-10-09 11:09:58 +13:00
William S Fulton
0a9113dcba
Correct php testcase
2017-09-19 07:37:29 +01:00
William S Fulton
9e2a12416c
Fix type promotion wrapping some non-trivial constant expressions
...
This was previously an integral type instead of a floating point type:
2017-09-18 07:06:27 +01:00
William S Fulton
90ba174fce
Fix generated code for constant expressions containing wchar_t L literals.
...
Such as:
# define __WCHAR_MAX (0x7fffffff + L'\0')
Reported on swig-user mailing list.
2017-09-17 19:02:55 +01:00
Nihal
7f72398eb6
Add tests for PHP pragma version to both PHP5 and PHP7.
...
Pragma version to specify version of PHP5 and PHP7 extensions.
See issue #360 .
2017-05-08 12:02:18 +05:30
William S Fulton
173c028dd4
Add test and changes entry for Python -builtin %array_class fix
...
Issue https://github.com/swig/swig/issues/446
2016-12-18 17:50:47 +00:00
Olly Betts
c8a5f84cd1
[PHP7] Wrap bool constants as PHP booleans
...
Leave PHP5 wrapping them as integers as this change could cause
incompatibilities.
Fixes issue https://github.com/swig/swig/issues/686 noted by Nishant
Gupta.
2016-11-30 17:19:11 +13:00
Olly Betts
c7f593e1b1
Enable li_factory testcase for PHP
...
It already works and already even has a runtest!
2016-11-30 13:07:36 +13:00
Olly Betts
1169874f59
[PHP] Add support for PHP7.
...
PHP5's C extension API has changed substantially so you need to use
-php7 to specify you want PHP7 compatible wrappers.
Fixes https://github.com/swig/swig/issues/571
2016-11-30 13:05:59 +13:00
William S Fulton
58461c1ffd
php run test fixes for new functions in testcase
2016-10-15 17:58:21 +01:00
Olly Betts
26bbc96d58
Arrange to return after calling zend_throw_exception()
...
Fixes github issue#240.
2016-09-16 17:54:02 +12:00
Olly Betts
a4015acaca
[PHP] Fix out typemap for member function pointers
...
The existing typemap was just broken - it correctly created the resource
and then did nothing with it, and instead tried to register the member
pointer as a normal pointer, which is never going to work as it's larger
than a normal pointer.
Add cpp_basic_runme.php as a regression test for this.
2016-09-02 09:51:18 +12:00
Olly Betts
888e9c6fec
Use preg_match() in PHP test harness code
...
ereg() and eregi() were deprecated in PHP 5.3.0 and removed in PHP 7.0.0,
and preg_match() has been available since PHP4.
2016-09-02 09:09:24 +12:00
William S Fulton
98a31ff633
Fix directorin SWIGTYPE typemaps to make a copy as these are used for pass by value.
...
Closes #434
2016-05-14 21:32:24 +01:00
William S Fulton
9600c95234
Duplicate tests that are run twice as both C and C++ tests to fix parallel make: li_carrays
2016-02-21 18:04:04 +00:00
Olly Betts
9e69a2c198
Use name of PHP resource not wrapped C++ type
...
Since callback::foo_T<int> isn't a PHP resource, that error message doesn't
really make sense as it was. As discussed in #467 .
2015-09-04 12:14:21 +12:00
William S Fulton
ca64b06229
Consistent quoting in Makefile
2015-08-21 22:48:34 +01:00
Vadim Zeitlin
a4b319ce8e
Remove callback function from autodoc unit test.
...
It doesn't seem to belong there at all, there is a dedicated callback unit
test for it and it was added to the initial version of autodoc.i back in
124253d698 without any explanation, so just
remove it.
As this callback was used in a PHP test, perform this test for callback.i now
and use "%(uppercase)s" construct inside %callback to test that this works.
2015-07-19 18:14:06 +02:00
Vadim Zeitlin
08fa873638
Make callback unit test pass for PHP backend.
...
Deprecated %callback(1) doesn't work with PHP, use "%s" to give the same name
to the callback as to the C function explicitly instead.
2015-07-19 00:13:08 +02:00
Olly Betts
ecf3ab5605
Disable director_thread_runme.php
...
This fails in a ZTS build of PHP.
2015-01-15 09:32:34 +13:00
William S Fulton
eec306c228
Test suite warning fixes
2014-12-28 10:38:12 +00:00
William S Fulton
3efd3affbd
Add c++11 strongly typed enum support for PHP
2014-11-27 19:59:20 +00:00
Olly Betts
1a99212c2c
[PHP] Add support for specifying any PHP interfaces a wrapped class
...
implements, e.g.: %typemap("phpinterfaces") MyIterator "Iterator";
2014-09-12 12:48:37 -03:00
Olly Betts
e12322df86
[PHP] Fix throwing a PHP exception through C++ from a subclassed
...
director method - PHP NULL gets returned by the subclassed method
in this case, so the directorout typemap needs to allow that (at
least if an exception is active).
2014-09-11 13:09:08 -03:00
Olly Betts
0dd7b61c57
Fix segmentation faults with directors in PHP >= 5.4
2014-09-09 13:39:30 -03:00
Karl Wette
7f48b2774b
Fully clean PHP test-suite
2014-05-29 02:29:27 +02:00
William S Fulton
176c697c8b
Remove PHP director_basic runtime test until fixed.
...
See #164
2014-05-18 01:06:56 +01:00
William S Fulton
2b5499a262
Slight simplification of test-suite build for new out-of-source changes
...
Provide default SRCDIR and SCRIPTDIR variables in common.mk and override
only where needed.
2014-05-15 23:11:07 +01:00
Karl Wette
f574a34155
Allow examples and test-suite to be built out of source tree
...
- Examples/Makefile.in rules use SRCDIR as the relative source directory
- ./config.status replicates Examples/ source directory tree in build
directory, and copies each Makefile to build directory, prefixed with
a header which sets SRCDIR to source directory
- Examples/test-suite/.../Makefile.in set SRCDIR from Autoconf-set srcdir
- Examples/test-suite/errors/Makefile.in needs to filter out source
directory from SWIG error messages
- Lua: embedded interpreters are passed location of run-time test
- Python: copy run-time scripts to build directory because of 2to3
conversion; import_packages example copies __init__.py from source
directory; test-suite sets SCRIPTDIR to location of run-time tests
- Javascript: binding.gyp renamed to binding.gyp.in so that $srcdir
can be substituted with SRCDIR; removed './' from require() statements
so that NODE_PATH can be used to point Node.js to build directory
2014-05-11 23:21:10 +02:00
Karl Wette
d5b765d388
Whitespace cleanup of all Makefiles*
...
- some of the %.clean rules in the test-suite Makefiles were using a single tab
as an empty rule, dangerous! I've replaced these with the safer '@exit 0'.
2014-05-02 20:06:11 +02:00
Olly Betts
73bb909bae
[PHP] The generated __isset() method now returns true for read-only properties.
2014-05-01 14:37:58 +12:00
Olly Betts
7df6c832c3
Remove incorrect comments
2014-02-19 18:27:14 +13:00
Olly Betts
6d08992945
Add expected functions which get generated to silence testsuite warning
2014-02-19 18:26:40 +13:00
Olly Betts
d67aed42bd
Remove executable bit from various test-suite runme files
2014-01-06 15:41:06 +13:00
William S Fulton
9f95e30650
Fix PHP test-suite running examples recently broken in 0fa791d
2013-04-20 02:51:57 +01:00
Olly Betts
7196e556a5
Fix SF#3528035, a regression introduced by the fix for SF#3428833.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13105 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-23 02:58:24 +00:00
Olly Betts
de9d01dbcd
[PHP] Fix getters for template members. (SF#3428833)
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13096 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-18 02:43:52 +00:00
Olly Betts
b32c70e244
Comment out use of call-time pass by reference, which has been deprecated for
...
ages, and is no longer supported by PHP 5.4.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13095 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-18 02:42:23 +00:00
Olly Betts
43b3e20d2f
Add wrapmacro_runme.php
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13065 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-11 05:58:18 +00:00
Olly Betts
fcb46fe2fa
[PHP] Fix the constant typemaps for SWIGTYPE, etc - previously
...
these used the wrong name for renamed constants. Add
autodoc_runme.php to the testsuite as a regression test for this.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13062 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-10 11:41:19 +00:00
Olly Betts
70a134872a
Remove two instances of call-time pass by reference, which has been removed in
...
PHP 5.4, and isn't needed for these tests anyway.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13060 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2012-05-10 10:37:42 +00:00
Olly Betts
748e951e7e
Add testcase virtual_vs_nonvirtual_base as a regression test for SF#3124665.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12715 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2011-05-25 05:19:48 +00:00
Olly Betts
72fc8be46c
[PHP] Fix handling of overloaded methods/functions where some
...
return void and others don't - whether this worked or not depended
on the order they were encountered in (SF#3208299).
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12539 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2011-03-14 12:33:56 +00:00
Olly Betts
5d765893ed
Simplify test-suite/overload_return_type.i (checked that it still fails before
...
the fix it's a regression test for) and added _runme.php for it.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12538 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2011-03-14 11:58:58 +00:00
Olly Betts
571204c98f
Fix typo which stopped %.test convenience helper from running multitests.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12519 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2011-03-07 03:14:24 +00:00
William S Fulton
4a73d986dd
Any 'using' statements in the protected section of a class were previously ignored with dirprot mode, certainly with Java and C#. Also directors - a call to a method being defined in the base class, not overridden in a subcalss, but again overridden in a class derived from the first subclass was not being dispatched correcly to the most derived class - affecting non-scripting languages. Fix for C# is based on recent fix for D.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12419 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2011-02-01 07:02:50 +00:00