William S Fulton
05d6717de9
Python builtin - add indexing support to std::set
2018-09-23 19:09:54 +01:00
William S Fulton
4715a4e72c
Python -builtin __contains__ fix for map and set like containers.
...
Fix when using -builtin and wrapping std::map, std::set, std::unordered_map or
std::unordered_set to ensure __contains__ is called. This is a wrapper for the STL
container's find method. Without it, Python will do its own slower sequence search.
2018-09-21 08:51:22 +01: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
Haoyu Bai
8f84447860
Commited SF#2158938: change all SWIG symbols start with Py to a new name.
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10961 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-12-03 18:43:44 +00:00
William S Fulton
da8791792b
STL fixes when using %import rather than %include and the Solaris Workshop compiler
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10424 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2008-05-07 21:33:19 +00:00
Marcelo Matus
cda225ea32
add iterator support
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@7766 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2005-10-31 09:56:13 +00:00
William S Fulton
03a67698a9
use exception specification instead of %exception to handle STL error checking
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@7352 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2005-07-27 20:09:42 +00:00
Marcelo Matus
877535badf
add set __getitem__ method, this allows python iterator syntax to work, as in 'for i in a_set:...'
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@7338 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2005-07-19 09:36:08 +00:00
William S Fulton
4fea1d827a
Various fixes for Visual C++ 7.1 and Sun Studio 10
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@7255 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2005-06-03 20:52:16 +00:00
Marcelo Matus
5b74ab97a7
more fixes for security and warnings
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@7009 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2005-02-26 20:25:10 +00:00
Marcelo Matus
6b499410dd
more fixes for template + def args
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@6833 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2004-12-05 10:15:25 +00:00
Marcelo Matus
dc4409a1f1
isolate language independent STD/STL/C++ code + more documentation + cleaning
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@6382 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2004-10-10 06:42:15 +00:00
Marcelo Matus
349e6bc6ee
using <> when including lib files, fix char{ANY], add char FIXSIZE[ANY], fix pyfragments.swg, fixing *.swg and *.i names
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@6250 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2004-09-17 06:17:35 +00:00
Marcelo Matus
49a09a63fb
more fixes for pointer
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@5824 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2004-04-03 08:36:08 +00:00
Marcelo Matus
ab44291de8
we better disable the comparison method generation by default.
...
reasons:
- before they were not generated, so, nobody will miss them,
and still they can be activated back using SWIG_STD_EXTEND_COMPARISON,
- the performance penalty is quite visible, and the solution is not
general, ie, for user types, still they need to be generated by hand.
Marcelo
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@5822 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2004-04-02 02:34:19 +00:00
Marcelo Matus
b85f90a6ed
fix pair for ptrs, and add SWIG_STD_NOEXTEND_COMPARISON to reduce swig times
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@5820 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2004-04-01 18:51:30 +00:00
Marcelo Matus
29a30e2dcc
- better support for classes with no default constructor, equal or
...
comparison methods.
you will be able to do
struct Foo {
Foo(int) {}
};
%std_nodefconst_type(Foo); // Says Foo has no def. constructor
%template(vector_Foo) std::vector<Foo>;
and the conflicting vector/list/deque methods will not be generated.
more cosmetic, and a note about the relation between std::map and
std::pair.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@5810 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2004-03-31 11:27:53 +00:00
Marcelo Matus
7afe6bc139
normalizing the inout typemaps and other cosmetic fixes
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@5782 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2004-03-21 23:26:18 +00:00
Marcelo Matus
1d5529bcfc
better STL support, see CHANGES.current
...
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@5755 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2004-03-17 09:41:19 +00:00