CGrammar: Don't pluralize "member" for structs with a single function pointer

This commit is contained in:
Pragmatic Software 2014-07-08 01:15:51 +00:00
parent cc0957b060
commit 0c8078c6db
2 changed files with 2 additions and 2 deletions

View File

@ -13,7 +13,7 @@ use warnings;
# These are set automatically by the build/commit script
use constant {
BUILD_NAME => "PBot",
BUILD_REVISION => 718,
BUILD_REVISION => 719,
BUILD_DATE => "2014-07-07",
};

View File

@ -1658,7 +1658,7 @@ struct_or_union_specifier:
my $identifier = join('',@{$item{'identifier(?)'}});
$return = join('',@{$item{'comment(?)'}}) . $item{struct_or_union};
if ($identifier) { $return .= " tagged $identifier"; }
my $plural = $item{struct_declaration_list} =~ / and / ? 's' : '';
my $plural = $item{struct_declaration_list} =~ / and (?!returning)/ ? 's' : '';
$return .= ", with member$plural $item{struct_declaration_list},";
}
| struct_or_union identifier