Commit 3d3a4b3a authored by Junchao Zhang's avatar Junchao Zhang
Browse files

Fix a perl script problem met with perl-5.8.8

To print out something like "$vec[$i]->base_addr", where @vec is an integer array,
the old perl is confused by "->" and thinks it is an operator. In fact, we just want
to print out "->base_addr" literally. Newer perl (e.g., 5.16.2) is fine with this syntax.

Change to "$vec[$i]"."->base_addr" to avoid this problem.

No review since F08 binding is experimental now.
parent 71f5e507
......@@ -550,7 +550,7 @@ EOT
# Temp variable declaration
for (my $i = 0; $i < $#vec; $i += 3) {
print CFILE " void *buf$vec[$i] = x$vec[$i]->base_addr;\n";
print CFILE " void *buf$vec[$i] = x$vec[$i]"."->base_addr;\n";
if ($vec[$i + 1] >= 0) {
print CFILE " int count$vec[$i] = x$vec[$i+1];\n";
print CFILE " MPI_Datatype dtype$vec[$i] = x$vec[$i+2];\n";
......@@ -572,7 +572,7 @@ EOT
# Test if a subarray arg is contiguous. If it is, generate a new datatype for it.
for (my $i = 0; $i < $#vec; $i += 3) {
if ($vec[$i + 1] >= 0) {
print CFILE " if (x$vec[$i]->rank != 0 && !CFI_is_contiguous(x$vec[$i])) {\n";
print CFILE " if (x$vec[$i]"."->rank != 0 && !CFI_is_contiguous(x$vec[$i])) {\n";
print CFILE " err = cdesc_create_datatype(x$vec[$i], x$vec[$i+1], x$vec[$i+2], &dtype$vec[$i]);\n";
print CFILE " count$vec[$i] = 1;\n";
print CFILE " }\n\n";
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment