9 character(len
=3, kind
=1), save :: str1a
[*], str1b(5)[*]
10 character(len
=7, kind
=1), save :: str2a
[*], str2b(5)[*]
11 character(len
=3, kind
=4), save :: ustr1a
[*], ustr1b(5)[*]
12 character(len
=7, kind
=4), save :: ustr2a
[*], ustr2b(5)[*]
14 ! ---------- Assign to coindexed variable -------------
16 ! - - - - - scalar = scalar
18 ! SCALAR - kind 1 - with padding
19 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
20 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
21 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
24 if (this_image() == num_images()) then
28 if (this_image() == 1) then
29 if (str2a
/= 1_
"abc ") STOP 1
31 if (str2a
/= 1_
"XXXXXXX") STOP 2
34 ! SCALAR - kind 4 - with padding
35 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
36 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
37 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
40 if (this_image() == num_images()) then
44 if (this_image() == 1) then
45 if (ustr2a
/= 4_
"abc ") STOP 3
47 if (ustr2a
/= 4_
"XXXXXXX") STOP 4
50 ! SCALAR - kind 1 - with trimming
51 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
52 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
53 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
56 if (this_image() == num_images()) then
60 if (this_image() == 1) then
61 if (str1a
/= 1_
"abc") STOP 5
63 if (str1a
/= 1_
"XXX") STOP 6
66 ! SCALAR - kind 4 - with trimming
67 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
68 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
69 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
72 if (this_image() == num_images()) then
76 if (this_image() == 1) then
77 if (ustr1a
/= 4_
"abc") STOP 7
79 if (ustr1a
/= 4_
"XXX") STOP 8
82 ! - - - - - array = array
84 ! contiguous ARRAY - kind 1 - with padding
85 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
86 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
87 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
91 str2b(1) = 1_
"XXXXXXX"
92 str2b(2) = 1_
"YYYYYYY"
93 str2b(3) = 1_
"ZZZZZZZ"
94 if (this_image() == num_images()) then
98 if (this_image() == 1) then
99 if (str2b(1) /= 1_
"abc " .or
. str2b(2) /= 1_
"def " &
100 .or
. str2b(3) /= 1_
"gjh ") STOP 9
102 if (str2b(1) /= 1_
"XXXXXXX" .or
. str2b(2) /= 1_
"YYYYYYY" &
103 .or
. str2b(3) /= 1_
"ZZZZZZZ") STOP 10
106 ! contiguous ARRAY - kind 4 - with padding
107 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
108 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
109 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
113 ustr2b(1) = 4_
"XXXXXXX"
114 ustr2b(2) = 4_
"YYYYYYY"
115 ustr2b(3) = 4_
"ZZZZZZZ"
116 if (this_image() == num_images()) then
117 ustr2b(:)[1] = ustr1b
120 if (this_image() == 1) then
121 if (ustr2b(1) /= 4_
"abc " .or
. ustr2b(2) /= 4_
"def " &
122 .or
. ustr2b(3) /= 4_
"gjh ") STOP 11
124 if (ustr2b(1) /= 4_
"XXXXXXX" .or
. ustr2b(2) /= 4_
"YYYYYYY" &
125 .or
. ustr2b(3) /= 4_
"ZZZZZZZ") STOP 12
128 ! contiguous ARRAY - kind 1 - with trimming
129 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
130 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
131 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
132 str2b(1) = 1_
"abcdefg"
133 str2b(2) = 1_
"hijklmn"
134 str2b(3) = 1_
"opqrstu"
138 if (this_image() == num_images()) then
142 if (this_image() == 1) then
143 if (str1b(1) /= 1_
"abc" .or
. str1b(2) /= 1_
"hij" &
144 .or
. str1b(3) /= 1_
"opq") STOP 13
146 if (str1b(1) /= 1_
"XXX" .or
. str1b(2) /= 1_
"YYY" &
147 .or
. str1b(3) /= 1_
"ZZZ") STOP 14
150 ! contiguous ARRAY - kind 4 - with trimming
151 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
152 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
153 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
154 ustr2b(1) = 4_
"abcdefg"
155 ustr2b(2) = 4_
"hijklmn"
156 ustr2b(3) = 4_
"opqrstu"
160 if (this_image() == num_images()) then
161 ustr1b(:)[1] = ustr2b
164 if (this_image() == 1) then
165 if (ustr1b(1) /= 4_
"abc" .or
. ustr1b(2) /= 4_
"hij" &
166 .or
. ustr1b(3) /= 4_
"opq") STOP 15
168 if (ustr1b(1) /= 4_
"XXX" .or
. ustr1b(2) /= 4_
"YYY" &
169 .or
. ustr1b(3) /= 4_
"ZZZ") STOP 16
172 ! - - - - - array = scalar
174 ! contiguous ARRAY - kind 1 - with padding
175 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
176 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
177 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
179 str2b(1) = 1_
"XXXXXXX"
180 str2b(2) = 1_
"YYYYYYY"
181 str2b(3) = 1_
"ZZZZZZZ"
182 if (this_image() == num_images()) then
186 if (this_image() == 1) then
187 if (str2b(1) /= 1_
"abc " .or
. str2b(2) /= 1_
"abc " &
188 .or
. str2b(3) /= 1_
"abc ") STOP 17
190 if (str2b(1) /= 1_
"XXXXXXX" .or
. str2b(2) /= 1_
"YYYYYYY" &
191 .or
. str2b(3) /= 1_
"ZZZZZZZ") STOP 18
194 ! contiguous ARRAY - kind 4 - with padding
195 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
196 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
197 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
199 ustr2b(1) = 4_
"XXXXXXX"
200 ustr2b(2) = 4_
"YYYYYYY"
201 ustr2b(3) = 4_
"ZZZZZZZ"
202 if (this_image() == num_images()) then
203 ustr2b(:)[1] = ustr1a
206 if (this_image() == 1) then
207 if (ustr2b(1) /= 4_
"abc " .or
. ustr2b(2) /= 4_
"abc " &
208 .or
. ustr2b(3) /= 4_
"abc ") STOP 19
210 if (ustr2b(1) /= 4_
"XXXXXXX" .or
. ustr2b(2) /= 4_
"YYYYYYY" &
211 .or
. ustr2b(3) /= 4_
"ZZZZZZZ") STOP 20
214 ! contiguous ARRAY - kind 1 - with trimming
215 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
216 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
217 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
222 if (this_image() == num_images()) then
226 if (this_image() == 1) then
227 if (str1b(1) /= 1_
"abc" .or
. str1b(2) /= 1_
"abc" &
228 .or
. str1b(3) /= 1_
"abc") STOP 21
230 if (str1b(1) /= 1_
"XXX" .or
. str1b(2) /= 1_
"YYY" &
231 .or
. str1b(3) /= 1_
"ZZZ") STOP 22
234 ! contiguous ARRAY - kind 4 - with trimming
235 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
236 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
237 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
242 if (this_image() == num_images()) then
243 ustr1b(:)[1] = ustr2a
246 if (this_image() == 1) then
247 if (ustr1b(1) /= 4_
"abc" .or
. ustr1b(2) /= 4_
"abc" &
248 .or
. ustr1b(3) /= 4_
"abc") STOP 23
250 if (ustr1b(1) /= 4_
"XXX" .or
. ustr1b(2) /= 4_
"YYY" &
251 .or
. ustr1b(3) /= 4_
"ZZZ") STOP 24
254 ! ---------- Take from a coindexed variable -------------
256 ! - - - - - scalar = scalar
258 ! SCALAR - kind 1 - with padding
259 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
260 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
261 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
264 if (this_image() == num_images()) then
268 if (this_image() == num_images()) then
269 if (str2a
/= 1_
"abc ") STOP 25
271 if (str2a
/= 1_
"XXXXXXX") STOP 26
274 ! SCALAR - kind 4 - with padding
275 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
276 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
277 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
280 if (this_image() == num_images()) then
284 if (this_image() == num_images()) then
285 if (ustr2a
/= 4_
"abc ") STOP 27
287 if (ustr2a
/= 4_
"XXXXXXX") STOP 28
290 ! SCALAR - kind 1 - with trimming
291 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
292 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
293 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
296 if (this_image() == num_images()) then
300 if (this_image() == num_images()) then
301 if (str1a
/= 1_
"abc") STOP 29
303 if (str1a
/= 1_
"XXX") STOP 30
306 ! SCALAR - kind 4 - with trimming
307 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
308 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
309 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
312 if (this_image() == num_images()) then
316 if (this_image() == num_images()) then
317 if (ustr1a
/= 4_
"abc") STOP 31
319 if (ustr1a
/= 4_
"XXX") STOP 32
322 ! - - - - - array = array
324 ! contiguous ARRAY - kind 1 - with padding
325 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
326 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
327 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
331 str2b(1) = 1_
"XXXXXXX"
332 str2b(2) = 1_
"YYYYYYY"
333 str2b(3) = 1_
"ZZZZZZZ"
334 if (this_image() == num_images()) then
338 if (this_image() == num_images()) then
339 if (str2b(1) /= 1_
"abc " .or
. str2b(2) /= 1_
"def " &
340 .or
. str2b(3) /= 1_
"gjh ") STOP 33
342 if (str2b(1) /= 1_
"XXXXXXX" .or
. str2b(2) /= 1_
"YYYYYYY" &
343 .or
. str2b(3) /= 1_
"ZZZZZZZ") STOP 34
346 ! contiguous ARRAY - kind 4 - with padding
347 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
348 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
349 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
353 ustr2b(1) = 4_
"XXXXXXX"
354 ustr2b(2) = 4_
"YYYYYYY"
355 ustr2b(3) = 4_
"ZZZZZZZ"
356 if (this_image() == num_images()) then
357 ustr2b
= ustr1b(:)[1]
360 if (this_image() == num_images()) then
361 if (ustr2b(1) /= 4_
"abc " .or
. ustr2b(2) /= 4_
"def " &
362 .or
. ustr2b(3) /= 4_
"gjh ") STOP 35
364 if (ustr2b(1) /= 4_
"XXXXXXX" .or
. ustr2b(2) /= 4_
"YYYYYYY" &
365 .or
. ustr2b(3) /= 4_
"ZZZZZZZ") STOP 36
368 ! contiguous ARRAY - kind 1 - with trimming
369 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
370 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
371 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
372 str2b(1) = 1_
"abcdefg"
373 str2b(2) = 1_
"hijklmn"
374 str2b(3) = 1_
"opqrstu"
378 if (this_image() == num_images()) then
382 if (this_image() == num_images()) then
383 if (str1b(1) /= 1_
"abc" .or
. str1b(2) /= 1_
"hij" &
384 .or
. str1b(3) /= 1_
"opq") STOP 37
386 if (str1b(1) /= 1_
"XXX" .or
. str1b(2) /= 1_
"YYY" &
387 .or
. str1b(3) /= 1_
"ZZZ") STOP 38
390 ! contiguous ARRAY - kind 4 - with trimming
391 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
392 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
393 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
394 ustr2b(1) = 4_
"abcdefg"
395 ustr2b(2) = 4_
"hijklmn"
396 ustr2b(3) = 4_
"opqrstu"
400 if (this_image() == num_images()) then
401 ustr1b
= ustr2b(:)[1]
404 if (this_image() == num_images()) then
405 if (ustr1b(1) /= 4_
"abc" .or
. ustr1b(2) /= 4_
"hij" &
406 .or
. ustr1b(3) /= 4_
"opq") STOP 39
408 if (ustr1b(1) /= 4_
"XXX" .or
. ustr1b(2) /= 4_
"YYY" &
409 .or
. ustr1b(3) /= 4_
"ZZZ") STOP 40
412 ! - - - - - array = scalar
414 ! contiguous ARRAY - kind 1 - with padding
415 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
416 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
417 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
419 str2b(1) = 1_
"XXXXXXX"
420 str2b(2) = 1_
"YYYYYYY"
421 str2b(3) = 1_
"ZZZZZZZ"
422 if (this_image() == num_images()) then
426 if (this_image() == num_images()) then
427 if (str2b(1) /= 1_
"abc " .or
. str2b(2) /= 1_
"abc " &
428 .or
. str2b(3) /= 1_
"abc ") STOP 41
430 if (str2b(1) /= 1_
"XXXXXXX" .or
. str2b(2) /= 1_
"YYYYYYY" &
431 .or
. str2b(3) /= 1_
"ZZZZZZZ") STOP 42
434 ! contiguous ARRAY - kind 4 - with padding
435 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
436 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
437 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
439 ustr2b(1) = 4_
"XXXXXXX"
440 ustr2b(2) = 4_
"YYYYYYY"
441 ustr2b(3) = 4_
"ZZZZZZZ"
442 if (this_image() == num_images()) then
446 if (this_image() == num_images()) then
447 if (ustr2b(1) /= 4_
"abc " .or
. ustr2b(2) /= 4_
"abc " &
448 .or
. ustr2b(3) /= 4_
"abc ") STOP 43
450 if (ustr2b(1) /= 4_
"XXXXXXX" .or
. ustr2b(2) /= 4_
"YYYYYYY" &
451 .or
. ustr2b(3) /= 4_
"ZZZZZZZ") STOP 44
454 ! contiguous ARRAY - kind 1 - with trimming
455 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
456 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
457 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
462 if (this_image() == num_images()) then
466 if (this_image() == num_images()) then
467 if (str1b(1) /= 1_
"abc" .or
. str1b(2) /= 1_
"abc" &
468 .or
. str1b(3) /= 1_
"abc") STOP 45
470 if (str1b(1) /= 1_
"XXX" .or
. str1b(2) /= 1_
"YYY" &
471 .or
. str1b(3) /= 1_
"ZZZ") STOP 46
474 ! contiguous ARRAY - kind 4 - with trimming
475 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
476 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
477 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
482 if (this_image() == num_images()) then
486 if (this_image() == num_images()) then
487 if (ustr1b(1) /= 4_
"abc" .or
. ustr1b(2) /= 4_
"abc" &
488 .or
. ustr1b(3) /= 4_
"abc") STOP 47
490 if (ustr1b(1) /= 4_
"XXX" .or
. ustr1b(2) /= 4_
"YYY" &
491 .or
. ustr1b(3) /= 4_
"ZZZ") STOP 48
495 ! ---------- coindexed to coindexed variable -------------
497 ! - - - - - scalar = scalar
499 ! SCALAR - kind 1 - with padding
500 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
501 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
502 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
505 if (this_image() == num_images()) then
506 str2a
[1] = str1a
[mod(1, num_images())+1]
509 if (this_image() == 1) then
510 if (str2a
/= 1_
"abc ") STOP 49
512 if (str2a
/= 1_
"XXXXXXX") STOP 50
515 ! SCALAR - kind 4 - with padding
516 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
517 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
518 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
521 if (this_image() == num_images()) then
522 ustr2a
[1] = ustr1a
[mod(1, num_images())+1]
525 if (this_image() == 1) then
526 if (ustr2a
/= 4_
"abc ") STOP 51
528 if (ustr2a
/= 4_
"XXXXXXX") STOP 52
531 ! SCALAR - kind 1 - with trimming
532 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
533 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
534 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
537 if (this_image() == num_images()) then
538 str1a
[1] = str2a
[mod(1, num_images())+1]
541 if (this_image() == 1) then
542 if (str1a
/= 1_
"abc") STOP 53
544 if (str1a
/= 1_
"XXX") STOP 54
547 ! SCALAR - kind 4 - with trimming
548 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
549 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
550 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
553 if (this_image() == num_images()) then
554 ustr1a
[1] = ustr2a
[mod(1, num_images())+1]
557 if (this_image() == 1) then
558 if (ustr1a
/= 4_
"abc") STOP 55
560 if (ustr1a
/= 4_
"XXX") STOP 56
563 ! - - - - - array = array
565 ! contiguous ARRAY - kind 1 - with padding
566 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
567 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
568 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
572 str2b(1) = 1_
"XXXXXXX"
573 str2b(2) = 1_
"YYYYYYY"
574 str2b(3) = 1_
"ZZZZZZZ"
575 if (this_image() == num_images()) then
576 str2b(:)[1] = str1b(:)[mod(1, num_images())+1]
579 if (this_image() == 1) then
580 if (str2b(1) /= 1_
"abc " .or
. str2b(2) /= 1_
"def " &
581 .or
. str2b(3) /= 1_
"gjh ") STOP 57
583 if (str2b(1) /= 1_
"XXXXXXX" .or
. str2b(2) /= 1_
"YYYYYYY" &
584 .or
. str2b(3) /= 1_
"ZZZZZZZ") STOP 58
587 ! contiguous ARRAY - kind 4 - with padding
588 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
589 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
590 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
594 ustr2b(1) = 4_
"XXXXXXX"
595 ustr2b(2) = 4_
"YYYYYYY"
596 ustr2b(3) = 4_
"ZZZZZZZ"
597 if (this_image() == num_images()) then
598 ustr2b(:)[1] = ustr1b(:)[mod(1, num_images())+1]
601 if (this_image() == 1) then
602 if (ustr2b(1) /= 4_
"abc " .or
. ustr2b(2) /= 4_
"def " &
603 .or
. ustr2b(3) /= 4_
"gjh ") STOP 59
605 if (ustr2b(1) /= 4_
"XXXXXXX" .or
. ustr2b(2) /= 4_
"YYYYYYY" &
606 .or
. ustr2b(3) /= 4_
"ZZZZZZZ") STOP 60
609 ! contiguous ARRAY - kind 1 - with trimming
610 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
611 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
612 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
613 str2b(1) = 1_
"abcdefg"
614 str2b(2) = 1_
"hijklmn"
615 str2b(3) = 1_
"opqrstu"
619 if (this_image() == num_images()) then
620 str1b(:)[1] = str2b(:)[mod(1, num_images())+1]
623 if (this_image() == 1) then
624 if (str1b(1) /= 1_
"abc" .or
. str1b(2) /= 1_
"hij" &
625 .or
. str1b(3) /= 1_
"opq") STOP 61
627 if (str1b(1) /= 1_
"XXX" .or
. str1b(2) /= 1_
"YYY" &
628 .or
. str1b(3) /= 1_
"ZZZ") STOP 62
631 ! contiguous ARRAY - kind 4 - with trimming
632 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
633 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
634 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
635 ustr2b(1) = 4_
"abcdefg"
636 ustr2b(2) = 4_
"hijklmn"
637 ustr2b(3) = 4_
"opqrstu"
641 if (this_image() == num_images()) then
642 ustr1b(:)[1] = ustr2b(:)[mod(1, num_images())+1]
645 if (this_image() == 1) then
646 if (ustr1b(1) /= 4_
"abc" .or
. ustr1b(2) /= 4_
"hij" &
647 .or
. ustr1b(3) /= 4_
"opq") STOP 63
649 if (ustr1b(1) /= 4_
"XXX" .or
. ustr1b(2) /= 4_
"YYY" &
650 .or
. ustr1b(3) /= 4_
"ZZZ") STOP 64
653 ! - - - - - array = scalar
655 ! contiguous ARRAY - kind 1 - with padding
656 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
657 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
658 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
660 str2b(1) = 1_
"XXXXXXX"
661 str2b(2) = 1_
"YYYYYYY"
662 str2b(3) = 1_
"ZZZZZZZ"
663 if (this_image() == num_images()) then
664 str2b(:)[1] = str1a
[mod(1, num_images())+1]
667 if (this_image() == 1) then
668 if (str2b(1) /= 1_
"abc " .or
. str2b(2) /= 1_
"abc " &
669 .or
. str2b(3) /= 1_
"abc ") STOP 65
671 if (str2b(1) /= 1_
"XXXXXXX" .or
. str2b(2) /= 1_
"YYYYYYY" &
672 .or
. str2b(3) /= 1_
"ZZZZZZZ") STOP 66
675 ! contiguous ARRAY - kind 4 - with padding
676 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
677 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
678 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
680 ustr2b(1) = 4_
"XXXXXXX"
681 ustr2b(2) = 4_
"YYYYYYY"
682 ustr2b(3) = 4_
"ZZZZZZZ"
683 if (this_image() == num_images()) then
684 ustr2b(:)[1] = ustr1a
[mod(1, num_images())+1]
687 if (this_image() == 1) then
688 if (ustr2b(1) /= 4_
"abc " .or
. ustr2b(2) /= 4_
"abc " &
689 .or
. ustr2b(3) /= 4_
"abc ") STOP 67
691 if (ustr2b(1) /= 4_
"XXXXXXX" .or
. ustr2b(2) /= 4_
"YYYYYYY" &
692 .or
. ustr2b(3) /= 4_
"ZZZZZZZ") STOP 68
695 ! contiguous ARRAY - kind 1 - with trimming
696 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
697 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
698 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
703 if (this_image() == num_images()) then
704 str1b(:)[1] = str2a
[mod(1, num_images())+1]
707 if (this_image() == 1) then
708 if (str1b(1) /= 1_
"abc" .or
. str1b(2) /= 1_
"abc" &
709 .or
. str1b(3) /= 1_
"abc") STOP 69
711 if (str1b(1) /= 1_
"XXX" .or
. str1b(2) /= 1_
"YYY" &
712 .or
. str1b(3) /= 1_
"ZZZ") STOP 70
715 ! contiguous ARRAY - kind 4 - with trimming
716 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
717 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
718 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
723 if (this_image() == num_images()) then
724 ustr1b(:)[1] = ustr2a
[mod(1, num_images())+1]
727 if (this_image() == 1) then
728 if (ustr1b(1) /= 4_
"abc" .or
. ustr1b(2) /= 4_
"abc" &
729 .or
. ustr1b(3) /= 4_
"abc") STOP 71
731 if (ustr1b(1) /= 4_
"XXX" .or
. ustr1b(2) /= 4_
"YYY" &
732 .or
. ustr1b(3) /= 4_
"ZZZ") STOP 72
735 ! ============== char1 <-> char4 =====================
737 ! ---------- Assign to coindexed variable -------------
739 ! - - - - - scalar = scalar
741 ! SCALAR - kind 1 <- 4 - with padding
742 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
743 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
744 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
747 if (this_image() == num_images()) then
751 if (this_image() == 1) then
752 if (str2a
/= 1_
"abc ") STOP 73
754 if (str2a
/= 1_
"XXXXXXX") STOP 74
757 ! SCALAR - kind 4 <- 1 - with padding
758 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
759 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
760 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
763 if (this_image() == num_images()) then
767 if (this_image() == 1) then
768 if (ustr2a
/= 4_
"abc ") STOP 75
770 if (ustr2a
/= 4_
"XXXXXXX") STOP 76
773 ! SCALAR - kind 1 <- 4 - with trimming
774 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
775 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
776 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
779 if (this_image() == num_images()) then
783 if (this_image() == 1) then
784 if (str1a
/= 1_
"abc") STOP 77
786 if (str1a
/= 1_
"XXX") STOP 78
789 ! SCALAR - kind 4 <- 1 - with trimming
790 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
791 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
792 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
795 if (this_image() == num_images()) then
799 if (this_image() == 1) then
800 if (ustr1a
/= 4_
"abc") STOP 79
802 if (ustr1a
/= 4_
"XXX") STOP 80
805 ! - - - - - array = array
807 ! contiguous ARRAY - kind 1 <- 4 - with padding
808 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
809 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
810 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
814 str2b(1) = 1_
"XXXXXXX"
815 str2b(2) = 1_
"YYYYYYY"
816 str2b(3) = 1_
"ZZZZZZZ"
817 if (this_image() == num_images()) then
821 if (this_image() == 1) then
822 if (str2b(1) /= 1_
"abc " .or
. str2b(2) /= 1_
"def " &
823 .or
. str2b(3) /= 1_
"gjh ") STOP 81
825 if (str2b(1) /= 1_
"XXXXXXX" .or
. str2b(2) /= 1_
"YYYYYYY" &
826 .or
. str2b(3) /= 1_
"ZZZZZZZ") STOP 82
829 ! contiguous ARRAY - kind 4 <- 1 - with padding
830 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
831 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
832 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
836 ustr2b(1) = 4_
"XXXXXXX"
837 ustr2b(2) = 4_
"YYYYYYY"
838 ustr2b(3) = 4_
"ZZZZZZZ"
839 if (this_image() == num_images()) then
843 if (this_image() == 1) then
844 if (ustr2b(1) /= 4_
"abc " .or
. ustr2b(2) /= 4_
"def " &
845 .or
. ustr2b(3) /= 4_
"gjh ") STOP 83
847 if (ustr2b(1) /= 4_
"XXXXXXX" .or
. ustr2b(2) /= 4_
"YYYYYYY" &
848 .or
. ustr2b(3) /= 4_
"ZZZZZZZ") STOP 84
851 ! contiguous ARRAY - kind 1 <- 4 - with trimming
852 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
853 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
854 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
855 ustr2b(1) = 4_
"abcdefg"
856 ustr2b(2) = 4_
"hijklmn"
857 ustr2b(3) = 4_
"opqrstu"
861 if (this_image() == num_images()) then
865 if (this_image() == 1) then
866 if (str1b(1) /= 1_
"abc" .or
. str1b(2) /= 1_
"hij" &
867 .or
. str1b(3) /= 1_
"opq") STOP 85
869 if (str1b(1) /= 1_
"XXX" .or
. str1b(2) /= 1_
"YYY" &
870 .or
. str1b(3) /= 1_
"ZZZ") STOP 86
873 ! contiguous ARRAY - kind 4 <- 1 - with trimming
874 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
875 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
876 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
877 str2b(1) = 1_
"abcdefg"
878 str2b(2) = 1_
"hijklmn"
879 str2b(3) = 1_
"opqrstu"
883 if (this_image() == num_images()) then
887 if (this_image() == 1) then
888 if (ustr1b(1) /= 4_
"abc" .or
. ustr1b(2) /= 4_
"hij" &
889 .or
. ustr1b(3) /= 4_
"opq") STOP 87
891 if (ustr1b(1) /= 4_
"XXX" .or
. ustr1b(2) /= 4_
"YYY" &
892 .or
. ustr1b(3) /= 4_
"ZZZ") STOP 88
895 ! - - - - - array = scalar
897 ! contiguous ARRAY - kind 1 <- 4 - with padding
898 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
899 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
900 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
902 str2b(1) = 1_
"XXXXXXX"
903 str2b(2) = 1_
"YYYYYYY"
904 str2b(3) = 1_
"ZZZZZZZ"
905 if (this_image() == num_images()) then
909 if (this_image() == 1) then
910 if (str2b(1) /= 1_
"abc " .or
. str2b(2) /= 1_
"abc " &
911 .or
. str2b(3) /= 1_
"abc ") STOP 89
913 if (str2b(1) /= 1_
"XXXXXXX" .or
. str2b(2) /= 1_
"YYYYYYY" &
914 .or
. str2b(3) /= 1_
"ZZZZZZZ") STOP 90
917 ! contiguous ARRAY - kind 4 <- 1 - with padding
918 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
919 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
920 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
922 ustr2b(1) = 4_
"XXXXXXX"
923 ustr2b(2) = 4_
"YYYYYYY"
924 ustr2b(3) = 4_
"ZZZZZZZ"
925 if (this_image() == num_images()) then
929 if (this_image() == 1) then
930 if (ustr2b(1) /= 4_
"abc " .or
. ustr2b(2) /= 4_
"abc " &
931 .or
. ustr2b(3) /= 4_
"abc ") STOP 91
933 if (ustr2b(1) /= 4_
"XXXXXXX" .or
. ustr2b(2) /= 4_
"YYYYYYY" &
934 .or
. ustr2b(3) /= 4_
"ZZZZZZZ") STOP 92
937 ! contiguous ARRAY - kind 1 <- 4 - with trimming
938 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
939 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
940 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
945 if (this_image() == num_images()) then
949 if (this_image() == 1) then
950 if (str1b(1) /= 1_
"abc" .or
. str1b(2) /= 1_
"abc" &
951 .or
. str1b(3) /= 1_
"abc") STOP 93
953 if (str1b(1) /= 1_
"XXX" .or
. str1b(2) /= 1_
"YYY" &
954 .or
. str1b(3) /= 1_
"ZZZ") STOP 94
957 ! contiguous ARRAY - kind 4 <- 1 - with trimming
958 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
959 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
960 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
965 if (this_image() == num_images()) then
969 if (this_image() == 1) then
970 if (ustr1b(1) /= 4_
"abc" .or
. ustr1b(2) /= 4_
"abc" &
971 .or
. ustr1b(3) /= 4_
"abc") STOP 95
973 if (ustr1b(1) /= 4_
"XXX" .or
. ustr1b(2) /= 4_
"YYY" &
974 .or
. ustr1b(3) /= 4_
"ZZZ") STOP 96
977 ! ---------- Take from a coindexed variable -------------
979 ! - - - - - scalar = scalar
981 ! SCALAR - kind 1 <- 4 - with padding
982 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
983 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
984 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
987 if (this_image() == num_images()) then
991 if (this_image() == num_images()) then
992 if (str2a
/= 1_
"abc ") STOP 97
994 if (str2a
/= 1_
"XXXXXXX") STOP 98
997 ! SCALAR - kind 4 <- 1 - with padding
998 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
999 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1000 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1002 ustr2a
= 4_
"XXXXXXX"
1003 if (this_image() == num_images()) then
1007 if (this_image() == num_images()) then
1008 if (ustr2a
/= 4_
"abc ") STOP 99
1010 if (ustr2a
/= 4_
"XXXXXXX") STOP 100
1013 ! SCALAR - kind 1 <- 4 - with trimming
1014 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1015 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1016 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1019 if (this_image() == num_images()) then
1023 if (this_image() == num_images()) then
1024 if (str1a
/= 1_
"abc") STOP 101
1026 if (str1a
/= 1_
"XXX") STOP 102
1029 ! SCALAR - kind 4 <- 1 - with trimming
1030 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1031 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1032 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1035 if (this_image() == num_images()) then
1039 if (this_image() == num_images()) then
1040 if (ustr1a
/= 4_
"abc") STOP 103
1042 if (ustr1a
/= 4_
"XXX") STOP 104
1045 ! - - - - - array = array
1047 ! contiguous ARRAY - kind 1 <- 4 - with padding
1048 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1049 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1050 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1054 str2b(1) = 1_
"XXXXXXX"
1055 str2b(2) = 1_
"YYYYYYY"
1056 str2b(3) = 1_
"ZZZZZZZ"
1057 if (this_image() == num_images()) then
1058 str2b
= ustr1b(:)[1]
1061 if (this_image() == num_images()) then
1062 if (str2b(1) /= 1_
"abc " .or
. str2b(2) /= 1_
"def " &
1063 .or
. str2b(3) /= 1_
"gjh ") STOP 105
1065 if (str2b(1) /= 1_
"XXXXXXX" .or
. str2b(2) /= 1_
"YYYYYYY" &
1066 .or
. str2b(3) /= 1_
"ZZZZZZZ") STOP 106
1069 ! contiguous ARRAY - kind 4 <- 1 - with padding
1070 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1071 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1072 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1076 ustr2b(1) = 4_
"XXXXXXX"
1077 ustr2b(2) = 4_
"YYYYYYY"
1078 ustr2b(3) = 4_
"ZZZZZZZ"
1079 if (this_image() == num_images()) then
1080 ustr2b
= str1b(:)[1]
1083 if (this_image() == num_images()) then
1084 if (ustr2b(1) /= 4_
"abc " .or
. ustr2b(2) /= 4_
"def " &
1085 .or
. ustr2b(3) /= 4_
"gjh ") STOP 107
1087 if (ustr2b(1) /= 4_
"XXXXXXX" .or
. ustr2b(2) /= 4_
"YYYYYYY" &
1088 .or
. ustr2b(3) /= 4_
"ZZZZZZZ") STOP 108
1091 ! contiguous ARRAY - kind 1 <- 4 - with trimming
1092 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1093 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1094 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1095 ustr2b(1) = 4_
"abcdefg"
1096 ustr2b(2) = 4_
"hijklmn"
1097 ustr2b(3) = 4_
"opqrstu"
1101 if (this_image() == num_images()) then
1102 str1b
= ustr2b(:)[1]
1105 if (this_image() == num_images()) then
1106 if (str1b(1) /= 1_
"abc" .or
. str1b(2) /= 1_
"hij" &
1107 .or
. str1b(3) /= 1_
"opq") STOP 109
1109 if (str1b(1) /= 1_
"XXX" .or
. str1b(2) /= 1_
"YYY" &
1110 .or
. str1b(3) /= 1_
"ZZZ") STOP 110
1113 ! contiguous ARRAY - kind 4 <- 1 - with trimming
1114 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1115 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1116 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1117 str2b(1) = 1_
"abcdefg"
1118 str2b(2) = 1_
"hijklmn"
1119 str2b(3) = 1_
"opqrstu"
1123 if (this_image() == num_images()) then
1124 ustr1b
= str2b(:)[1]
1127 if (this_image() == num_images()) then
1128 if (ustr1b(1) /= 4_
"abc" .or
. ustr1b(2) /= 4_
"hij" &
1129 .or
. ustr1b(3) /= 4_
"opq") STOP 111
1131 if (ustr1b(1) /= 4_
"XXX" .or
. ustr1b(2) /= 4_
"YYY" &
1132 .or
. ustr1b(3) /= 4_
"ZZZ") STOP 112
1135 ! - - - - - array = scalar
1137 ! contiguous ARRAY - kind 1 <- 4 - with padding
1138 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1139 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1140 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1142 str2b(1) = 1_
"XXXXXXX"
1143 str2b(2) = 1_
"YYYYYYY"
1144 str2b(3) = 1_
"ZZZZZZZ"
1145 if (this_image() == num_images()) then
1149 if (this_image() == num_images()) then
1150 if (str2b(1) /= 1_
"abc " .or
. str2b(2) /= 1_
"abc " &
1151 .or
. str2b(3) /= 1_
"abc ") STOP 113
1153 if (str2b(1) /= 1_
"XXXXXXX" .or
. str2b(2) /= 1_
"YYYYYYY" &
1154 .or
. str2b(3) /= 1_
"ZZZZZZZ") STOP 114
1157 ! contiguous ARRAY - kind 4 <- 1 - with padding
1158 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1159 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1160 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1162 ustr2b(1) = 4_
"XXXXXXX"
1163 ustr2b(2) = 4_
"YYYYYYY"
1164 ustr2b(3) = 4_
"ZZZZZZZ"
1165 if (this_image() == num_images()) then
1169 if (this_image() == num_images()) then
1170 if (ustr2b(1) /= 4_
"abc " .or
. ustr2b(2) /= 4_
"abc " &
1171 .or
. ustr2b(3) /= 4_
"abc ") STOP 115
1173 if (ustr2b(1) /= 4_
"XXXXXXX" .or
. ustr2b(2) /= 4_
"YYYYYYY" &
1174 .or
. ustr2b(3) /= 4_
"ZZZZZZZ") STOP 116
1177 ! contiguous ARRAY - kind 1 <- 4 - with trimming
1178 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1179 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1180 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1181 ustr2a
= 4_
"abcdefg"
1185 if (this_image() == num_images()) then
1189 if (this_image() == num_images()) then
1190 if (str1b(1) /= 1_
"abc" .or
. str1b(2) /= 1_
"abc" &
1191 .or
. str1b(3) /= 1_
"abc") STOP 117
1193 if (str1b(1) /= 1_
"XXX" .or
. str1b(2) /= 1_
"YYY" &
1194 .or
. str1b(3) /= 1_
"ZZZ") STOP 118
1197 ! contiguous ARRAY - kind 4 <- 1 - with trimming
1198 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1199 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1200 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1205 if (this_image() == num_images()) then
1209 if (this_image() == num_images()) then
1210 if (ustr1b(1) /= 4_
"abc" .or
. ustr1b(2) /= 4_
"abc" &
1211 .or
. ustr1b(3) /= 4_
"abc") STOP 119
1213 if (ustr1b(1) /= 4_
"XXX" .or
. ustr1b(2) /= 4_
"YYY" &
1214 .or
. ustr1b(3) /= 4_
"ZZZ") STOP 120
1218 ! ---------- coindexed to coindexed variable -------------
1220 ! - - - - - scalar = scalar
1222 ! SCALAR - kind 1 <- 4 - with padding
1223 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1224 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1225 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1228 if (this_image() == num_images()) then
1229 str2a
[1] = ustr1a
[mod(1, num_images())+1]
1232 if (this_image() == 1) then
1233 if (str2a
/= 1_
"abc ") STOP 121
1235 if (str2a
/= 1_
"XXXXXXX") STOP 122
1238 ! SCALAR - kind 4 <- 1 - with padding
1239 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1240 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1241 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1243 ustr2a
= 4_
"XXXXXXX"
1244 if (this_image() == num_images()) then
1245 ustr2a
[1] = str1a
[mod(1, num_images())+1]
1248 if (this_image() == 1) then
1249 if (ustr2a
/= 4_
"abc ") STOP 123
1251 if (ustr2a
/= 4_
"XXXXXXX") STOP 124
1254 ! SCALAR - kind 1 <- 4 - with trimming
1255 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1256 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1257 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1260 if (this_image() == num_images()) then
1261 str1a
[1] = ustr2a
[mod(1, num_images())+1]
1264 if (this_image() == 1) then
1265 if (str1a
/= 1_
"abc") STOP 125
1267 if (str1a
/= 1_
"XXX") STOP 126
1270 ! SCALAR - kind 4 <- 1 - with trimming
1271 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1272 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1273 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1276 if (this_image() == num_images()) then
1277 ustr1a
[1] = str2a
[mod(1, num_images())+1]
1280 if (this_image() == 1) then
1281 if (ustr1a
/= 4_
"abc") STOP 127
1283 if (ustr1a
/= 4_
"XXX") STOP 128
1286 ! - - - - - array = array
1288 ! contiguous ARRAY - kind 1 <- 4 - with padding
1289 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1290 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1291 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1295 str2b(1) = 1_
"XXXXXXX"
1296 str2b(2) = 1_
"YYYYYYY"
1297 str2b(3) = 1_
"ZZZZZZZ"
1298 if (this_image() == num_images()) then
1299 str2b(:)[1] = ustr1b(:)[mod(1, num_images())+1]
1302 if (this_image() == 1) then
1303 if (str2b(1) /= 1_
"abc " .or
. str2b(2) /= 1_
"def " &
1304 .or
. str2b(3) /= 1_
"gjh ") STOP 129
1306 if (str2b(1) /= 1_
"XXXXXXX" .or
. str2b(2) /= 1_
"YYYYYYY" &
1307 .or
. str2b(3) /= 1_
"ZZZZZZZ") STOP 130
1310 ! contiguous ARRAY - kind 4 <- 1 - with padding
1311 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1312 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1313 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1317 ustr2b(1) = 4_
"XXXXXXX"
1318 ustr2b(2) = 4_
"YYYYYYY"
1319 ustr2b(3) = 4_
"ZZZZZZZ"
1320 if (this_image() == num_images()) then
1321 ustr2b(:)[1] = str1b(:)[mod(1, num_images())+1]
1324 if (this_image() == 1) then
1325 if (ustr2b(1) /= 4_
"abc " .or
. ustr2b(2) /= 4_
"def " &
1326 .or
. ustr2b(3) /= 4_
"gjh ") STOP 131
1328 if (ustr2b(1) /= 4_
"XXXXXXX" .or
. ustr2b(2) /= 4_
"YYYYYYY" &
1329 .or
. ustr2b(3) /= 4_
"ZZZZZZZ") STOP 132
1332 ! contiguous ARRAY - kind 1 <- 4 - with trimming
1333 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1334 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1335 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1336 ustr2b(1) = 4_
"abcdefg"
1337 ustr2b(2) = 4_
"hijklmn"
1338 ustr2b(3) = 4_
"opqrstu"
1342 if (this_image() == num_images()) then
1343 str1b(:)[1] = ustr2b(:)[mod(1, num_images())+1]
1346 if (this_image() == 1) then
1347 if (str1b(1) /= 1_
"abc" .or
. str1b(2) /= 1_
"hij" &
1348 .or
. str1b(3) /= 1_
"opq") STOP 133
1350 if (str1b(1) /= 1_
"XXX" .or
. str1b(2) /= 1_
"YYY" &
1351 .or
. str1b(3) /= 1_
"ZZZ") STOP 134
1354 ! contiguous ARRAY - kind 4 <- 1 - with trimming
1355 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1356 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1357 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1358 str2b(1) = 1_
"abcdefg"
1359 str2b(2) = 1_
"hijklmn"
1360 str2b(3) = 1_
"opqrstu"
1364 if (this_image() == num_images()) then
1365 ustr1b(:)[1] = str2b(:)[mod(1, num_images())+1]
1368 if (this_image() == 1) then
1369 if (ustr1b(1) /= 4_
"abc" .or
. ustr1b(2) /= 4_
"hij" &
1370 .or
. ustr1b(3) /= 4_
"opq") STOP 135
1372 if (ustr1b(1) /= 4_
"XXX" .or
. ustr1b(2) /= 4_
"YYY" &
1373 .or
. ustr1b(3) /= 4_
"ZZZ") STOP 136
1376 ! - - - - - array = scalar
1378 ! contiguous ARRAY - kind 1 <- 4 - with padding
1379 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1380 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1381 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1383 str2b(1) = 1_
"XXXXXXX"
1384 str2b(2) = 1_
"YYYYYYY"
1385 str2b(3) = 1_
"ZZZZZZZ"
1386 if (this_image() == num_images()) then
1387 str2b(:)[1] = ustr1a
[mod(1, num_images())+1]
1390 if (this_image() == 1) then
1391 if (str2b(1) /= 1_
"abc " .or
. str2b(2) /= 1_
"abc " &
1392 .or
. str2b(3) /= 1_
"abc ") STOP 137
1394 if (str2b(1) /= 1_
"XXXXXXX" .or
. str2b(2) /= 1_
"YYYYYYY" &
1395 .or
. str2b(3) /= 1_
"ZZZZZZZ") STOP 138
1398 ! contiguous ARRAY - kind 4 <- 1 - with padding
1399 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1400 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1401 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1403 ustr2b(1) = 4_
"XXXXXXX"
1404 ustr2b(2) = 4_
"YYYYYYY"
1405 ustr2b(3) = 4_
"ZZZZZZZ"
1406 if (this_image() == num_images()) then
1407 ustr2b(:)[1] = str1a
[mod(1, num_images())+1]
1410 if (this_image() == 1) then
1411 if (ustr2b(1) /= 4_
"abc " .or
. ustr2b(2) /= 4_
"abc " &
1412 .or
. ustr2b(3) /= 4_
"abc ") STOP 139
1414 if (ustr2b(1) /= 4_
"XXXXXXX" .or
. ustr2b(2) /= 4_
"YYYYYYY" &
1415 .or
. ustr2b(3) /= 4_
"ZZZZZZZ") STOP 140
1418 ! contiguous ARRAY - kind 1 <- 4 - with trimming
1419 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1420 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1421 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1422 ustr2a
= 4_
"abcdefg"
1426 if (this_image() == num_images()) then
1427 str1b(:)[1] = ustr2a
[mod(1, num_images())+1]
1430 if (this_image() == 1) then
1431 if (str1b(1) /= 1_
"abc" .or
. str1b(2) /= 1_
"abc" &
1432 .or
. str1b(3) /= 1_
"abc") STOP 141
1434 if (str1b(1) /= 1_
"XXX" .or
. str1b(2) /= 1_
"YYY" &
1435 .or
. str1b(3) /= 1_
"ZZZ") STOP 142
1438 ! contiguous ARRAY - kind 4 <- 1 - with trimming
1439 str1a
= 1_
"zzz"; str1b
= 1_
"zzz"; ustr1a
= 4_
"zzz"; ustr1b
= 4_
"zzz"
1440 str2a
= 1_
"zzzzzzzz"; str2b
= 1_
"zzzzzzzz"
1441 ustr2a
= 4_
"zzzzzzzz"; ustr2b
= 4_
"zzzzzzzz"
1446 if (this_image() == num_images()) then
1447 ustr1b(:)[1] = str2a
[mod(1, num_images())+1]
1450 if (this_image() == 1) then
1451 if (ustr1b(1) /= 4_
"abc" .or
. ustr1b(2) /= 4_
"abc" &
1452 .or
. ustr1b(3) /= 4_
"abc") STOP 143
1454 if (ustr1b(1) /= 4_
"XXX" .or
. ustr1b(2) /= 4_
"YYY" &
1455 .or
. ustr1b(3) /= 4_
"ZZZ") STOP 144
1458 end subroutine char_test