Support class method calls without parenthesis
It is possible to call a class method without parenthesis if no arguments are specified. At the moment this works when calling a class method by name. But when using the implicit class handle `this` or `super` it does not work. Add support for this. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
This commit is contained in:
parent
da5b9a4e5f
commit
51eae02e78
6
parse.y
6
parse.y
|
|
@ -6641,11 +6641,11 @@ statement_item /* This is roughly statement_item in the LRM */
|
||||||
$$ = tmp;
|
$$ = tmp;
|
||||||
}
|
}
|
||||||
|
|
||||||
| class_hierarchy_identifier '(' expression_list_with_nuls ')' ';'
|
| class_hierarchy_identifier argument_list_parens_opt ';'
|
||||||
{ PCallTask*tmp = new PCallTask(*$1, *$3);
|
{ PCallTask*tmp = new PCallTask(*$1, *$2);
|
||||||
FILE_NAME(tmp, @1);
|
FILE_NAME(tmp, @1);
|
||||||
delete $1;
|
delete $1;
|
||||||
delete $3;
|
delete $2;
|
||||||
$$ = tmp;
|
$$ = tmp;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue