From: Tassilo von Parseval Date: Fri, 21 May 2004 10:51:58 +0000 (+0200) Subject: h2xs doesn't recognize indented enums X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=797af06457c688e661ef6a212830baedd6918294;p=p5sagit%2Fp5-mst-13.2.git h2xs doesn't recognize indented enums Message-id: <20040521085158.GA10660@ethan> (modified regexp) p4raw-id: //depot/perl@22836 --- diff --git a/utils/h2xs.PL b/utils/h2xs.PL index 2e8e23e..9132bc9 100644 --- a/utils/h2xs.PL +++ b/utils/h2xs.PL @@ -900,7 +900,7 @@ if( @path_h ){ next if $opt_e && $enum_name =~ /$opt_e/; my $val = 0; for my $item (split /,/, $enum_body) { - my ($key, $declared_val) = $item =~ /(\w*)\s*=\s*(.*)/; + my ($key, $declared_val) = $item =~ /(\w+)\s*=\s*(.*)/; $val = length($declared_val) ? $declared_val : 1 + $val; $seen_define{$key} = $declared_val; $const_names{$key}++;