summaryrefslogtreecommitdiff
path: root/ext/Encode/bin
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2006-09-15 22:03:53 +0000
committerNicholas Clark <nick@ccl4.org>2006-09-15 22:03:53 +0000
commit9f20e2cfb903d33f1df637b45bc92463e8540f62 (patch)
tree5acd49e44f180165aba65495492726ba19775ea1 /ext/Encode/bin
parentccba5138c721ec441e594caee909f33438a87b7a (diff)
downloadperl-9f20e2cfb903d33f1df637b45bc92463e8540f62.tar.gz
Avoid warnings when $Config{d_cplusplus} is undefined.
p4raw-id: //depot/perl@28849
Diffstat (limited to 'ext/Encode/bin')
-rw-r--r--ext/Encode/bin/enc2xs6
1 files changed, 3 insertions, 3 deletions
diff --git a/ext/Encode/bin/enc2xs b/ext/Encode/bin/enc2xs
index 8a85ca0893..7665fa5b04 100644
--- a/ext/Encode/bin/enc2xs
+++ b/ext/Encode/bin/enc2xs
@@ -689,7 +689,7 @@ sub addstrings
}
if ($a->{'Forward'})
{
- my $cpp = $Config{d_cplusplus} eq 'define';
+ my $cpp = ($Config{d_cplusplus} || '') eq 'define';
my $var = $^O eq 'MacOS' || $cpp ? 'extern' : 'static';
my $const = $cpp ? '' : 'const';
print $fh "$var $const encpage_t $name\[",scalar(@{$a->{'Entries'}}),"];\n";
@@ -755,7 +755,7 @@ sub outbigstring
}
$strings = length $string_acc;
- my $cpp = $Config{d_cplusplus} eq 'define';
+ my $cpp = ($Config{d_cplusplus} || '') eq 'define';
my $var = $cpp ? '' : 'static';
my $definition = "\n$var const U8 $name\[$strings] = { " .
join(',',unpack "C*",$string_acc);
@@ -782,7 +782,7 @@ sub outtable
my ($s,$e,$out,$t,$end,$l) = @$b;
outtable($fh,$t,$bigname) unless $t->{'Done'};
}
- my $cpp = $Config{d_cplusplus} eq 'define';
+ my $cpp = ($Config{d_cplusplus} || '') eq 'define';
my $var = $cpp ? '' : 'static';
my $const = $cpp ? '' : 'const';
print $fh "\n$var $const encpage_t $name\[",