~laney/ubuntu/quantal/swig2.0/guile-2.0

« back to all changes in this revision

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

  • Committer: Bazaar Package Importer
  • Author(s): Torsten Landschoff
  • Date: 2011-05-03 22:34:43 UTC
  • Revision ID: james.westby@ubuntu.com-20110503223443-2f1pqulejz92wiqn
Tags: 2.0.3-2
* Package a snapshot of the upcoming upstream release 2.0.4. This matches
  upstream revision r12653.
  + Fixes building of Python 3.2 bindings (closes: #622980).

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
%module array_typedef_memberin
2
2
%inline %{ 
3
 
typedef short arr_short8[8]; 
 
3
typedef short Eight[8]; 
 
4
typedef const short ConstEight[8]; 
4
5
namespace ArrayExample 
5
6
6
7
    class ExampleDetail 
7
8
    { 
8
9
    public: 
9
 
        arr_short8 node_list; 
10
 
     }; 
 
10
        Eight node_list; 
 
11
#ifndef _MSC_VER
 
12
        const Eight node_list2; 
 
13
        ConstEight node_list3; 
 
14
#else
 
15
        Eight node_list2; 
 
16
        Eight node_list3; 
 
17
#endif
 
18
 
 
19
        void fn1(Eight a) {}
 
20
        void fn2(const Eight a) {}
 
21
        void fn3(ConstEight a) {}
 
22
 
 
23
        void fn4(Eight* a) {}
 
24
        void fn5(ConstEight* a) {}
 
25
        void fn6(const ConstEight* a) {}
 
26
 
 
27
        void fn7(Eight*& a) {}
 
28
        void fn8(ConstEight*& a) {}
 
29
        void fn9(const ConstEight*& a) {}
 
30
    };
11
31
 
32
 
 
33
typedef int Four[4];
 
34
typedef const int ConstFour[4];
 
35
 
 
36
void test_1(int (*v)[4]) {}
 
37
void test_2(Four *v) {}
 
38
void test_3(const Four *v) {}
 
39
void test_4(ConstFour *v) {}
 
40
void test_5(const int (*v)[4]) {}
 
41
void test_3r(const Four *&v) {}
 
42
void test_4r(ConstFour *&v) {}
12
43
%}