summaryrefslogtreecommitdiff
path: root/Examples/test-suite/octave/namespace_typemap_runme.m
blob: d7e338104f7db2d88c612580f0040d05ba662d89 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
namespace_typemap

if (!strcmp(stest1("hello"),"hello"))
    error("failed");
endif

if (!strcmp(stest2("hello"),"hello"))
    error("failed");
endif

if (!strcmp(stest3("hello"),"hello"))
    error("failed");
endif

if (!strcmp(stest4("hello"),"hello"))
    error("failed");
endif

if (!strcmp(stest5("hello"),"hello"))
    error("failed");
endif

if (!strcmp(stest6("hello"),"hello"))
    error("failed");
endif

if (!strcmp(stest7("hello"),"hello"))
    error("failed");
endif

if (!strcmp(stest8("hello"),"hello"))
    error("failed");
endif

if (!strcmp(stest9("hello"),"hello"))
    error("failed");
endif

if (!strcmp(stest10("hello"),"hello"))
    error("failed");
endif

if (!strcmp(stest11("hello"),"hello"))
    error("failed");
endif

if (!strcmp(stest12("hello"),"hello"))
    error("failed");
endif

c = complex(2,3);
r = real(c);

if (ctest1(c) != r)
    error("failed");
endif

if (ctest2(c) != r)
    error("failed");
endif

if (ctest3(c) != r)
    error("failed");
endif

if (ctest4(c) != r)
    error("failed");
endif

if (ctest5(c) != r)
    error("failed");
endif

if (ctest6(c) != r)
    error("failed");
endif

if (ctest7(c) != r)
    error("failed");
endif

if (ctest8(c) != r)
    error("failed");
endif

if (ctest9(c) != r)
    error("failed");
endif

if (ctest10(c) != r)
    error("failed");
endif

if (ctest11(c) != r)
    error("failed");
endif

if (ctest12(c) != r)
    error("failed");
endif

try
    ttest1(-14)
    error("failed");
catch
end_try_catch