[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] scratch/last-cedet-merge 8571383 16/37: semantic: Incorpor
From: |
David Engster |
Subject: |
[Emacs-diffs] scratch/last-cedet-merge 8571383 16/37: semantic: Incorporate local scope when finding type |
Date: |
Sun, 22 Jan 2017 21:26:32 +0000 (UTC) |
branch: scratch/last-cedet-merge
commit 85713839e192ed03ba028c760688ae23b134cd5c
Author: Eric Ludlam <address@hidden>
Commit: David Engster <address@hidden>
semantic: Incorporate local scope when finding type
* lisp/cedet/semantic/analyze/fcn.el (semantic-analyze-tag-type): When
first search fails, calc scope from the originating tag, and try
again.
---
lisp/cedet/semantic/analyze/fcn.el | 11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/lisp/cedet/semantic/analyze/fcn.el
b/lisp/cedet/semantic/analyze/fcn.el
index 1abbca5..24f71bb 100644
--- a/lisp/cedet/semantic/analyze/fcn.el
+++ b/lisp/cedet/semantic/analyze/fcn.el
@@ -183,7 +183,16 @@ Optional SCOPE represents a calculated scope in which the
types might be found. This can be nil.
If NOMETADEREF, then do not dereference metatypes. This is
used by the analyzer debugger."
- (semantic-analyze-type (semantic-tag-type tag) scope nometaderef))
+ (or
+ (semantic-analyze-type (semantic-tag-type tag) scope nometaderef)
+ ;; If we didn't find it the 'quick' way with the passed in scope,
+ ;; perhaps the type is using a shorthand only available from the
+ ;; location of TAG, which might be a member of some struct far away
+ ;; from the original source that spawned the search.
+ (let ((tagscope (semantic-calculate-scope-for-tag tag)))
+ (when tagscope
+ (semantic-analyze-type (semantic-tag-type tag)
+ tagscope nometaderef)))))
(defun semantic-analyze-type (type-declaration &optional scope nometaderef)
"Return the semantic tag for TYPE-DECLARATION.
- [Emacs-diffs] scratch/last-cedet-merge 2b42323 35/37: EDE: Fix for project detection, (continued)
- [Emacs-diffs] scratch/last-cedet-merge 2b42323 35/37: EDE: Fix for project detection, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge b4d1399 14/37: EDE: Rework config file detection, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge deaa8c9 24/37: semantic: New function to find library with macro definition, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge 6b57c5b 20/37: semantic: Introduce `semantic-analyze-tag-type-members', David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge 0a2b38b 26/37: EDE: Expand file name, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge fb127f2 34/37: semantic: C grammar fixes, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge f11e08f 10/37: semantic: Fix wisent parser recursion, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge 47471b9 12/37: EDE: Add missing require and silence byte compiler, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge 6ca095c 21/37: semantic: Add autoload for Add autoload for `semantic-analyze-debug-assist', David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge 5cb7aed 22/37: semantic: New c-mode override for analyzing tag type members, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge 8571383 16/37: semantic: Incorporate local scope when finding type,
David Engster <=
- [Emacs-diffs] scratch/last-cedet-merge 74263b1 37/37: semantic: Change unary expression rule, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge 03c5f0d 25/37: semantic: Add more syntax modifications for scheme lexer, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge ebc59a5 19/37: semantic: Accept FLAGS parameter for srecode-template-mode, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge 02644fe 36/37: semantic: Add missing save-excursion for scope calculation, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge 278c06c 31/37: semantic: Optimize 'typeformbase' in C grammar, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge cfd7139 28/37: semantic: Some C grammar optimizations, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge f3674d0 33/37: semantic: Parse C++ override/final correctly, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge 6d6b045 27/37: EDE: Improve Emacs project type, David Engster, 2017/01/22
- [Emacs-diffs] scratch/last-cedet-merge b4bcc84 32/37: semantic: completion fixes, David Engster, 2017/01/22