Skip to content

Commit 96337b2

Browse files
xavier98erezgeva
authored andcommitted
Octave argcargvtest
1 parent 35ec8ca commit 96337b2

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
argcargvtest
2+
3+
largs={'hi','hola','hello'};
4+
if (mainc(largs) != 3)
5+
error("bad main typemap");
6+
endif
7+
8+
targs={'hi','hola'};
9+
if (mainv(targs,1) != 'hola')
10+
error("bad main typemap");
11+
endif
12+
13+
targs={'hi', 'hola'};
14+
if (mainv(targs,1) != 'hola')
15+
error("bad main typemap");
16+
endif
17+
18+
try
19+
error_flag = 0;
20+
mainv('hello',1);
21+
error_flag = 1;
22+
catch
23+
end_try_catch
24+
if (error_flag)
25+
error("bad main typemap")
26+
endif
27+
28+
29+
initializeApp(largs);

0 commit comments

Comments
 (0)