~ubuntu-branches/ubuntu/oneiric/swig1.3/oneiric

« back to all changes in this revision

Viewing changes to Examples/test-suite/li_boost_shared_ptr_bits.i

  • Committer: Bazaar Package Importer
  • Author(s): Michael Vogt
  • Date: 2008-06-20 18:33:37 UTC
  • mfrom: (1.2.7 upstream)
  • Revision ID: james.westby@ubuntu.com-20080620183337-hockvwcewu29409c
Tags: 1.3.35-4ubuntu1
* Merge from debian unstable, remaining changes:
  - Drop support for pike.
  - Use python2.5 instead of python2.4.
  - use php5
  - Clean Runtime/ as well.
  - Force a few environment variables.
  - debian/Rules (clean): Remove Lib/ocaml/swigp4.ml.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
%module li_boost_shared_ptr_bits
 
2
 
 
3
#if defined(SWIGJAVA) || defined(SWIGCSHARP) || defined(SWIGPYTHON)
 
4
#define SHARED_PTR_WRAPPERS_IMPLEMENTED
 
5
#endif
 
6
 
 
7
#if defined(SHARED_PTR_WRAPPERS_IMPLEMENTED)
 
8
 
 
9
%include <boost_shared_ptr.i>
 
10
SWIG_SHARED_PTR(NonDynamic, NonDynamic)
 
11
 
 
12
#endif
 
13
 
 
14
#if defined(SWIGPYTHON)
 
15
%pythonnondynamic NonDynamic;
 
16
#endif
 
17
 
 
18
%inline %{
 
19
#include <boost/shared_ptr.hpp>
 
20
struct NonDynamic {
 
21
  int i;
 
22
};
 
23
boost::shared_ptr<NonDynamic> boing(boost::shared_ptr<NonDynamic> b) { return b; }
 
24
%}
 
25