| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
SWIG uses these internally in type strings so needs to rewrite them
when they appear in expressions which get used in a type. This
already happens, but really deserves test coverage.
|
|
|
|
|
|
|
|
|
|
| |
This was being rejected by SWIG because the type string contains
'<' not followed by '('. That check seems too strict given types
can contain constant expressions which can contain '<' characters
in several ways, so let's just try removing the check and see what
happens.
Fixes #2486
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously we had a hard-coded list of allowed combinations in the
grammar, but this suffers from combinatorial explosion, and results
in a vague `Syntax error in input` error for invalid (and missing)
combinations.
This means we now support a number of cases which are valid C++
but weren't supported.
Fixes #302
Fixes #2079 (friend constexpr)
Fixes #2474 (virtual explicit)
|
| |
|
|
|
|
|
|
|
| |
So far C#, Java, Lua and PHP are supported.
Closes: #2540
See #1567
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
We now wrap this as a non-static method in PHP, which means the static
form only callable via an object.
Previously this case could end up wrapped as static or non-static
in PHP. If it was wrapped as static, attempting to call non-static
overloaded forms would crash with a segmentation fault.
See #2544
|
| |
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* typedef-namespace:
Partial revert of previous commit for typedefs
add an unit test
tentative fix for typedef/using declaration to struct typedef
Conflicts:
CHANGES.current
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Setting current symbol table for a typedef seems wrong.
No difference to test-suite though.
Testcase rename for C++11 testing and minor adjustments.
Issue #2550
Closes #2551
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| | |
We no longer need to now we've dropped D1 support.
|
| | |
|
| | |
|
| |
| |
| |
| | |
See #2538
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
We aim to produce code that works with C90 or C++98 so we can't
assume snprintf() is available, but it almost always is (even
on systems from before it was standardised) so having a way to
use it is helpful.
Enable this automatically if the compiler claims conformance
with at least C90 or C++98 and check SWIG_HAVE_SNPRINTF to allow
turning on manually, but disable if SWIG_NO_SNPRINTF if defined.
The fallback is to call sprintf() without a buffer size check -
checking after the call is really shutting the stable door after
the horse has bolted, and most of our uses either have a fixed maximum
possible size or dynamically allocate a buffer that's large enough.
Fixes: #2502 (sprintf deprecation warnings on macos)
Fixes: #2548
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
SWIG_LUA_CONSTTAB_INT can be called with a constant expression
containing commas (e.g. `SizeOf< int,int >::size`). This was
addressed in b13f584258079dd88a4ca87412b87ac4464686df by making
its second argument variadic, but (a) this doesn't work with
our baseline of C90/C++98 and (b) the variadic syntax used is
a GCC extension which doesn't work with all compilers (e.g. MSVC).
We can solve this without needing variadic macros by simply wrapping
this argument in an extra pair of parentheses when calling.
|
| |
| |
| |
| | |
This reverts commit b13f584258079dd88a4ca87412b87ac4464686df.
|
|\ \
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
* python-iterator-protocol:
Finish removal of SwigPySequence_Cont
Remove undocumented and non-existent STL std::carray
Remove assign method uses by the removed Python Sequence Protocol
Remove now redundant use of Python Sequence protocol in STL wrappers
Add support for all STL containers to be constructible from a Python set
Iterator Protocol support for std::array wrappers
STL support for copying Python objects supporting Iterator protocol
Closes #2515
Conflicts:
CHANGES.current
|
| | | |
|
| | | |
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Removes SwigPySequence_Cont and support classes:
SwigPySequence_ArrowProxy, SwigPySequence_Cont, SwigPySequence_Ref
The recently added Iterator Protocol support should cover the Sequence
Protocol usage for converting from Python containers to STL containers.
|
| | | |
|
| | |
| | |
| | |
| | |
| | | |
Introduce swig::IteratorProtocol class and assign which can be partially
specialized by different container types, such as std::array.
|
| | |
| | |
| | |
| | | |
std::array not working though
|
|\ \ \ |
|
| | | |
| | | |
| | | |
| | | | |
I don't have access to jsc atm
|
| | |/
| |/| |
|
| | |
| | |
| | |
| | | |
There's no need to do a substring check here.
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Use c_str() only when we need a terminating zero byte and data() when
we don't (as we already did in most cases). The two methods in fact
do the same thing as of C++11 (and in practice did for all C++98
implementations I'm aware of) but it's useful to make clear when we need
a terminating zero byte and when we don't, for example for adding
string_view support (string_view supports data(), but can't support
c_str() (since it could be a slice from the middle of a std::string).
|
|/ /
| |
| |
| |
| | |
The format was changed from that the manual shows in 2010 by
5a3ba0d607132bfe78c5c23b3d8d2694a9250957!
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Previously the default was always "node", even if nodejs wasn't
detected by configure. This leads to a confusing failure from
"make check" if you have another support JS engine installed
but not node.
Now the default it picked based on which engines configure
found. If only one was detected, that should be used. If
multiple are, you can override the default choice by specifying
e.g. ENGINE=jsc on the make command line.
Fixes #2453
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Nodejs is like V8 and needs C++ output enabled when wrapping C code.
The testsuite was masking this bug by using SWIG options
`-v8 -DBUILDING_NODE_EXTENSION=1` rather than `-node` when testing
with nodejs, while the javascript examples currently all seem to all get
processed with -c++.
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| | |
By default SWIG/PHP wraps std::string& as a pass-by-reference PHP
string parameter, but sometimes such a parameter is only for input
or only for output, so add support for the named typemaps that other
target languages support.
|
| |
| |
| |
| | |
Fixes #2528
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This method checks if the range of the input variable is fine.
However if the errno variable was already set, it fails even for valid inputs.
This fixes at least some random failures in the python castmode.
Fixes: #2519
|
| | |
|