diff options
author | Father Chrysostomos <sprout@cpan.org> | 2011-12-22 22:51:50 -0800 |
---|---|---|
committer | Father Chrysostomos <sprout@cpan.org> | 2011-12-24 09:25:20 -0800 |
commit | 1b6e87415847fb00091c22c1eeb1dbd6cece377a (patch) | |
tree | e472361005fa19679ae63b57df76e11b48e71044 /regen | |
parent | ef744b2941d9092cc1d28a001826c37cdc49b359 (diff) | |
download | perl-1b6e87415847fb00091c22c1eeb1dbd6cece377a.tar.gz |
Make MAX_FEATURE_LEN reflect reality
unicode_strings was not the longest string. We can determine it auto-
matically, now that this macro is in a generated file.
Diffstat (limited to 'regen')
-rwxr-xr-x | regen/feature.pl | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/regen/feature.pl b/regen/feature.pl index 44861a2adf..20cfd4fcf1 100755 --- a/regen/feature.pl +++ b/regen/feature.pl @@ -220,10 +220,14 @@ print $h <<'EOH'; & HINT_LOCALIZE_HH) \ && Perl_feature_is_enabled(aTHX_ STR_WITH_LEN(name))) /* The longest string we pass in. */ -#define MAX_FEATURE_LEN (sizeof("unicode_strings")-1) - EOH +my $longest_internal_feature_name = longest values %feature; +print $h <<EOL; +#define MAX_FEATURE_LEN (sizeof("$longest_internal_feature_name")-1) + +EOL + for ( sort { length $a <=> length $b } keys %feature ) { |