The great merge
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@4141 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
6fcc22a1f8
commit
516036631c
1508 changed files with 125983 additions and 44037 deletions
|
|
@ -120,14 +120,13 @@ For example:
|
|||
|
||||
<blockquote>
|
||||
<pre>
|
||||
Circle_x_set $c 15 ;# Set member data
|
||||
Shape_x_set $c 15 ;# Set member data
|
||||
set x [Shape_x_get $c] ;# Get member data
|
||||
</pre>
|
||||
</blockquote>
|
||||
|
||||
Note: when accessing member data, the name of the base class or the derived class can be
|
||||
used in the function name as shown above. Of course, it would probably be more
|
||||
proper to just use the base class version such as <tt>Shape_x_get</tt>
|
||||
Note: when accessing member data, the name of the base class must
|
||||
be used such as <tt>Shape_x_get</tt>
|
||||
|
||||
<p>
|
||||
<li>To invoke a member function, you simply do this
|
||||
|
|
@ -270,28 +269,6 @@ to write a helper function. For example:
|
|||
<p>
|
||||
<li>Namespaces. Not supported at all. Won't be supported until SWIG2.0 (if at all).
|
||||
|
||||
<p>
|
||||
<li>Templates. Not supported at all. SWIG throws out anything that looks like a template.
|
||||
You can work around the problem by aliasing a template class behind a typedef however.
|
||||
For example:
|
||||
|
||||
<blockquote>
|
||||
<pre>
|
||||
%{
|
||||
typedef vector<int> IntVector;
|
||||
%}
|
||||
|
||||
class IntVector {
|
||||
public:
|
||||
... methods ...
|
||||
};
|
||||
</pre>
|
||||
</blockquote>
|
||||
</ul>
|
||||
<p>
|
||||
<li>There is no guarantee that an extremely complex C++ application will be able to compile
|
||||
as a Python extension. Sorry.
|
||||
|
||||
</ul>
|
||||
|
||||
<hr>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue