[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] scratch/last-cedet-merge e698dc1 04/37: semantic: Add supp
From: |
David Engster |
Subject: |
[Emacs-diffs] scratch/last-cedet-merge e698dc1 04/37: semantic: Add support for typedef references |
Date: |
Sun, 22 Jan 2017 21:26:31 +0000 (UTC) |
branch: scratch/last-cedet-merge
commit e698dc189984301a33558bd90dab7dea55c18e50
Author: David Engster <address@hidden>
Commit: David Engster <address@hidden>
semantic: Add support for typedef references
* admin/grammars/c.by (typedefname): Also parse optional reference
qualifier.
* lisp/cedet/semantic/bovine/c.el (semantic-expand-c-tag-namelist):
Add :reference attribute for typedefs.
---
admin/grammars/c.by | 4 ++--
lisp/cedet/semantic/bovine/c.el | 5 ++++-
2 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/admin/grammars/c.by b/admin/grammars/c.by
index c312fd6..b8c150a 100644
--- a/admin/grammars/c.by
+++ b/admin/grammars/c.by
@@ -450,8 +450,8 @@ typedef-symbol-list
;; TODO: Klaus Berndl: symbol -> namespace-symbol?! Answer: Probably
;; symbol is correct here!
typedefname
- : opt-stars symbol opt-bits opt-array
- ( $1 $2 )
+ : opt-stars opt-ref symbol opt-bits opt-array
+ ( $1 $2 $3 )
;
struct-or-class
diff --git a/lisp/cedet/semantic/bovine/c.el b/lisp/cedet/semantic/bovine/c.el
index 5d7d5a6..47a5457 100644
--- a/lisp/cedet/semantic/bovine/c.el
+++ b/lisp/cedet/semantic/bovine/c.el
@@ -1187,13 +1187,16 @@ is its own toplevel tag. This function will return
(cons A B)."
(while names
(setq vl (cons (semantic-tag-new-type
- (nth 1 (car names)) ; name
+ (nth 2 (car names)) ; name
"typedef"
(semantic-tag-type-members tag)
nil
:pointer
(let ((stars (car (car (car names)))))
(if (= stars 0) nil stars))
+ :reference
+ (let ((refs (car (nth 1 (car names)))))
+ (when (> refs 0) refs))
;; This specifies what the typedef
;; is expanded out as. Just the
;; name shows up as a parent of this
- [Emacs-diffs] branch scratch/last-cedet-merge created (now 74263b1), David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge ca20c99 01/37: semantic: make semanticdb-default-find-index-class buffer-local, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge 05d6b4b 03/37: semantic: Apply enum-type to all members, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge e698dc1 04/37: semantic: Add support for typedef references,
David Engster <=
- [Emacs-diffs] scratch/last-cedet-merge 5776e7c 06/37: EDE: Fallback to project-linux-build-directory-default if necessary, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge 307b510 09/37: semantic: Deal with missing prefix when completing symbol, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge fa84466 07/37: semantic: Fix current symbol info, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge fdd5968 15/37: semantic: New function to calculate scope around tag, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge 8daca76 30/37: semantic: C grammar optimizations, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge 40dd3d9 02/37: semantic: Do not add enum-type for every type, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge a7276f6 08/37: ; semantic: Add TODO comment regarding arg indexing, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge 5d6f4b8 05/37: EDE: Fix slot type in ede-proj-target-makefile, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge ec4505d 17/37: semantic: Accept FLAGS in texinfo-mode for analyzing completions, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge 0391760 13/37: semantic: Do not strip '*' from operator, David Engster, 2017/01/22