Grammar bug fixes from CEDET upstream.
* grammars/c.by (function-pointer): Correctly deal with anonymous function pointers. (opt-brackets-after-symbol): New. (multi-stage-dereference): Use it. Add rules for explicit matching the last dereference.
This commit is contained in:
parent
9d37482ce3
commit
a60a2b6db2
2 changed files with 23 additions and 4 deletions
|
@ -1,3 +1,11 @@
|
|||
2014-02-06 David Engster <deng@randomsample.de>
|
||||
|
||||
* grammars/c.by (function-pointer): Correctly deal with anonymous
|
||||
function pointers.
|
||||
(opt-brackets-after-symbol): New.
|
||||
(multi-stage-dereference): Use it. Add rules for explicit
|
||||
matching the last dereference.
|
||||
|
||||
2014-01-16 Eric S. Raymond <esr@thyrsus.com>
|
||||
|
||||
* notes/commits: Add a 'graph on VCS-independent ways of
|
||||
|
|
|
@ -1113,8 +1113,8 @@ functionname
|
|||
;
|
||||
|
||||
function-pointer
|
||||
: LPAREN STAR symbol RPAREN
|
||||
( (concat "*" $3) )
|
||||
: LPAREN STAR opt-symbol RPAREN
|
||||
( (concat "*" ,(car $3)) )
|
||||
| LPAREN symbol RPAREN
|
||||
( $2 )
|
||||
;
|
||||
|
@ -1154,14 +1154,25 @@ type-cast-list
|
|||
: open-paren typeformbase close-paren
|
||||
;
|
||||
|
||||
opt-brackets-after-symbol
|
||||
: brackets-after-symbol
|
||||
| ;; EMPTY
|
||||
;
|
||||
|
||||
brackets-after-symbol
|
||||
: PAREN_BLCK
|
||||
| BRACK_BLCK
|
||||
;
|
||||
|
||||
multi-stage-dereference
|
||||
: namespace-symbol brackets-after-symbol PERIOD multi-stage-dereference ;; method call
|
||||
| namespace-symbol brackets-after-symbol MINUS GREATER multi-stage-dereference ;;method call
|
||||
: namespace-symbol opt-brackets-after-symbol
|
||||
PERIOD multi-stage-dereference ;; method call
|
||||
| namespace-symbol opt-brackets-after-symbol
|
||||
MINUS GREATER multi-stage-dereference ;;method call
|
||||
| namespace-symbol opt-brackets-after-symbol
|
||||
PERIOD namespace-symbol opt-brackets-after-symbol
|
||||
| namespace-symbol opt-brackets-after-symbol
|
||||
MINUS GREATER namespace-symbol opt-brackets-after-symbol
|
||||
| namespace-symbol brackets-after-symbol
|
||||
;
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue