Lines Matching full:have

13 my @have;
15 @have = ();
19 push @have, "$q;$r";
21 is("@have", 'A;B C;D', 'explicit list');
23 @have = ();
26 push @have, "$q;$r";
28 is("@have", 'D;C B;A', 'explicit list reversed');
30 @have = ();
33 push @have, "$q;$r";
35 is("@have", 'A;B C;D E;F', 'explicit list three iterations');
37 @have = ();
40 push @have, "$q;$r;$s";
42 is("@have", 'A;B;C D;E;F', 'explicit list triplets');
44 @have = ();
47 push @have, "$q;$r;$s";
49 is("@have", 'A;B;C D;E;F', 'trailing comma n-fold');
51 @have = ();
54 push @have, join ';', map { $_ // 'undef' } $q, $r, $s;
57 is("@have", 'A;B;C D;E;undef', 'incomplete explicit list');
59 @have = ();
62 push @have, join ';', map { $_ // 'undef' } $q, $r, $s;
65 is("@have", 'E;D;C B;A;undef', 'incomplete explicit list reversed');
68 @have = ();
71 push @have, $q;
73 is("@have", 'A B C D E F', 'trailing comma one-at-a-time');
75 @have = ();
78 push @have, $q;
80 is("@have", 'A B C D E F', 'one-at-a-time');
83 # Arrays have an optimised case in pp_iter:
87 @array = split ' ', 'Dogs have owners, cats have staff.';
91 @have = ();
94 push @have, "$q;$r;$s";
96 is("@have", 'Dogs;have;owners, cats;have;staff.', 'package array');
99 @have = ();
102 push @have, "$q;$r;$s";
104 is("@have", 'staff.;have;cats owners,;have;Dogs', 'package array reversed');
107 @have = ();
110 push @have, join ';', map { $_ // '!' } $q, $r, $s, $t;
112 is("@have", 'Dogs;have;owners,;cats have;staff.;!;!', 'incomplete package array');
114 @have = ();
117 push @have, join ';', map { $_ // '!' } $q, $r, $s, $t;
119 is("@have", 'staff.;have;cats;owners, have;Dogs;!;!', 'incomplete package array reversed');
126 is("@array", 'have Dogs cats owners, staff. have', 'package array aliased');
134 @have = ();
137 push @have, "$q;$r;$s";
139 is("@have", 'God;is;real, unless;declared;integer.', 'lexical array');
142 @have = ();
145 push @have, "$q;$r;$s";
147 is("@have", 'integer.;declared;unless real,;is;God', 'lexical array reversed');
150 @have = ();
153 push @have, join ';', map { $_ // '!' } $q, $r, $s, $t;
155 is("@have", 'God;is;real,;unless declared;integer.;!;!', 'incomplete lexical array');
158 @have = ();
161 push @have, join ';', map { $_ // '!' } $q, $r, $s, $t;
163 is("@have", 'integer.;declared;unless;real, is;God;!;!', 'incomplete lexical array reversed');
172 # Integer ranges have an optimised case in pp_iter:
173 @have = ();
176 push @have, "$q;$r;$s";
179 is("@have", '0;1;2 3;4;5', 'integer list');
181 @have = ();
184 push @have, "$q;$r;$s";
187 is("@have", '5;4;3 2;1;0', 'integer list reversed');
189 @have = ();
192 push @have, join ';', map { $_ // 'undef' } $q, $r, $s;
195 is("@have", '1;2;3 4;5;undef', 'incomplete integer list');
197 @have = ();
200 push @have, join ';', map { $_ // 'Thunderbirds are go' } $q, $r, $s;
203 is("@have", '5;4;3 2;1;Thunderbirds are go', 'incomplete integer list reversed');
205 # String ranges have an optimised case in pp_iter:
206 @have = ();
209 push @have, "$q;$r;$s";
212 is("@have", 'A;B;C D;E;F', 'string list');
214 @have = ();
217 push @have, "$q;$r;$s";
220 is("@have", 'F;E;D C;B;A', 'string list reversed');
222 @have = ();
225 push @have, join ';', map { $_ // 'undef' } $q, $r, $s;
228 is("@have", 'B;C;D E;F;undef', 'incomplete string list');
230 @have = ();
233 push @have, join ';', map { $_ // 'undef' } $q, $r, $s;
236 is("@have", 'F;E;D C;B;undef', 'incomplete string list reversed');
248 @have = ();
251 push @have, "$key;$value";
254 my $got = "@have";
262 @have = ();
265 push @have, "$key;$value";
268 $got = "@have";
299 @have = ();
302 push @have, "$key;$value";
305 my $got = "@have";
313 @have = ();
316 push @have, "$key;$value";
319 $got = "@have";
435 @have = ();
437 push @have, "$domestic;$wild";
439 is("@have", 'alpaca;guanaco llama;vicuña', 'comma test 0');
441 @have = ();
443 push @have, "$domestic;$wild";
445 is("@have", 'alpaca;guanaco llama;vicuña', 'comma test 1');
447 @have = ();
449 push @have, "$domestic;$wild";
451 is("@have", 'alpaca;guanaco llama;vicuña', 'comma test 2');
453 @have = ();
455 push @have, "$domestic;$wild";
457 is("@have", 'alpaca;guanaco llama;vicuña', 'comma test 3');
459 @have = ();
461 push @have, "$domestic;$wild";
463 is("@have", 'alpaca;guanaco llama;vicuña', 'comma test 42');
470 @have = ();
473 push @have, $one;
475 is("@have", "@correct", 'for my ($one)');
477 @have = ();
480 push @have, $one;
482 is("@have", "@correct", 'for my($one)');
484 @have = ();
489 push @have, "$end end $orientation";
491 is("@have", "Pointy end Up Flamey end Down", 'for my ($one, $two)');
493 @have = ();
496 push @have, "$end end $orientation";
498 is("@have", "Pointy end Up Flamey end Down", 'for my ($one, $two)');