mirror of
https://github.com/pragma-/pbot.git
synced 2024-11-30 07:59:42 +01:00
CGrammar: Function prototypes can appear in delcaration section
This commit is contained in:
parent
0f5dbeda7a
commit
9597833b32
@ -13,7 +13,7 @@ use warnings;
|
|||||||
# These are set automatically by the build/commit script
|
# These are set automatically by the build/commit script
|
||||||
use constant {
|
use constant {
|
||||||
BUILD_NAME => "PBot",
|
BUILD_NAME => "PBot",
|
||||||
BUILD_REVISION => 635,
|
BUILD_REVISION => 636,
|
||||||
BUILD_DATE => "2014-06-12",
|
BUILD_DATE => "2014-06-12",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -614,7 +614,8 @@ declaration_list:
|
|||||||
{ $return = join('', @{$item{'preproc(?)'}}) . join('', @{$item{'declaration(s)'}}); }
|
{ $return = join('', @{$item{'preproc(?)'}}) . join('', @{$item{'declaration(s)'}}); }
|
||||||
|
|
||||||
declaration:
|
declaration:
|
||||||
declaration_specifiers init_declarator_list(?) ';'
|
function_prototype
|
||||||
|
| declaration_specifiers init_declarator_list(?) ';'
|
||||||
{
|
{
|
||||||
# This whole thing needs to be re-written to parse declarations inside-out.
|
# This whole thing needs to be re-written to parse declarations inside-out.
|
||||||
my @init_list = defined $item{'init_declarator_list(?)'}->[0] ? @{$item{'init_declarator_list(?)'}->[0]} : ('');
|
my @init_list = defined $item{'init_declarator_list(?)'}->[0] ? @{$item{'init_declarator_list(?)'}->[0]} : ('');
|
||||||
|
Loading…
Reference in New Issue
Block a user