summaryrefslogtreecommitdiff
path: root/lisp/cedet/semantic/scope.el
diff options
context:
space:
mode:
authorChong Yidong <cyd@stupidchicken.com>2009-09-03 03:58:13 +0000
committerChong Yidong <cyd@stupidchicken.com>2009-09-03 03:58:13 +0000
commit55b522b2eb02de72ce207a04aef15ed7f193b568 (patch)
tree6c42de0ee2603dc9dfa410704579290610bc1eeb /lisp/cedet/semantic/scope.el
parentd8dbeec0af29501ed4cf409a9860e63d7ac0cf0e (diff)
downloademacs-55b522b2eb02de72ce207a04aef15ed7f193b568.tar.gz
lisp/cedet/semantic/analyze.el: Add local vars for autoloading.
(semantic-analyze-current-context): Autoload. lisp/cedet/semantic/ctxt.el: Add local vars for autoloading. Don't eval-when-compile semantic/db (semantic-ctxt-current-mode): Autoload. (semantic-up-context): Require semantic/find. lisp/cedet/semantic/find.el (semantic-current-tag-parent) (semantic-find-tags-by-scope-protection): Autoload. lisp/cedet/semantic/format.el (semantic-format-tag-prototype) (semantic-format-tag-summarize): Autoload. lisp/cedet/semantic/idle.el: Declare external functions. (semantic-idle-work-for-one-buffer, semantic-idle-work-core-handler): Require semantic/db-mode. (semantic-idle-work-core-handler): Synch to upstream. (semantic-idle-scheduler-refresh-tags): Require semantic/decorate/mode. (semantic-idle-summary-find-current-symbol-tag): Require semantic/db-find. (semantic-idle-summary-current-symbol-info-context): Require semantic/analyze. (semantic-idle-summary-maybe-highlight, semantic-idle-tag-highlight): Require pulse. (semantic-idle-completion-list-default): Require semantic/complete. lisp/cedet/semantic/lex-spp.el: Require semantic. (semantic-lex-spp-analyzer-push-tokens-for-symbol): Synch to upstream. (semantic-lex-spp-first-token-arg-list): Use split-string. lisp/cedet/semantic/lex.el: Declare semantic-elapsed-time. Add local vars for autoloading. (semantic-lex-test): Require semantic. (semantic-lex): Autoload. (semantic-flex): Use semantic-lex-keyword-p to avoid compiler warning. lisp/cedet/semantic/sb.el: Require semantic/sort. Declare semanticdb-minor-mode-p. (semantic-sb-fetch-tag-table): Require semantic/db-mode. lisp/cedet/semantic/scope.el: eval-when-compile semantic/find. Declare external functions. (semantic-analyze-scope-nested-tags-default): Require semantic/analyze. (semantic-analyze-show): Require semantic/analyze. (semantic-calculate-scope): Require semantic/db-typecache. lisp/cedet/semantic/sort.el: Add local vars for autoloading. Declare semanticdb-find-tags-external-children-of-type. (semantic-flatten-tags-table, semantic-tag-external-member-parent): Autoload. (semantic-tag-external-member-children-default): Require semantic/db-find. lisp/cedet/semantic/symref.el: Require semantic. Declare data-debug-new-buffer and data-debug-insert-object-slots. (semantic-symref-data-debug-last-result): Require eieio-datadebug. lisp/cedet/semantic/tag-file.el: Declare external functions. (semantic-go-to-tag): Call semanticdb-table-child-p only if semantic/db is loaded. (semantic-dependency-tag-file): Require semantic/dep. lisp/cedet/semantic/tag-ls.el: Require semantic. Add local variables for autoloading. (semantic-tag-prototype-p): Autoload. lisp/cedet/semantic/tag-write.el: Require semantic. lisp/cedet/semantic/tag.el: Update external function declarations and requirements, removing autoloaded functions. Add local vars for autoloading. (semantic-tag-components): Autoload. lisp/cedet/semantic/texi.el: Declare lookup-words. eval-when-compile semantic/find. lisp/cedet/semantic/util.el: Update file header. lisp/cedet/semantic/analyze/complete.el: Add local variables for autoloading. (semantic-analyze-possible-completions, semantic-analyze-type-constants): Autoload.
Diffstat (limited to 'lisp/cedet/semantic/scope.el')
-rw-r--r--lisp/cedet/semantic/scope.el15
1 files changed, 14 insertions, 1 deletions
diff --git a/lisp/cedet/semantic/scope.el b/lisp/cedet/semantic/scope.el
index c89bd79978f..603fdc23576 100644
--- a/lisp/cedet/semantic/scope.el
+++ b/lisp/cedet/semantic/scope.el
@@ -49,6 +49,13 @@
(require 'semantic/analyze/fcn)
(require 'semantic/ctxt)
+(eval-when-compile (require 'semantic/find)) ; For semantic-find-* macros
+
+(declare-function data-debug-show "eieio-datadebug")
+(declare-function semantic-analyze-find-tag "semantic/analyze")
+(declare-function semantic-analyze-princ-sequence "semantic/analyze")
+(declare-function semanticdb-typecache-merge-streams "semantic/db-typecache")
+(declare-function semanticdb-typecache-add-dependant "semantic/db-typecache")
;;; Code:
@@ -175,6 +182,7 @@ types available.")
(defun semantic-analyze-scoped-types-default (position)
"Return a list of types currently in scope at POSITION.
Use `semantic-ctxt-scoped-types' to find types."
+ (require 'semantic/db-typecache)
(save-excursion
(goto-char position)
(let ((code-scoped-types nil))
@@ -221,6 +229,7 @@ Optional SCOPETYPES are additional scoped entities in which our parent might
be found.
This only finds ONE immediate parent by name. All other parents returned
are from nesting data types."
+ (require 'semantic/analyze)
(save-excursion
(if position (goto-char position))
(let* ((stack (reverse (semantic-find-tag-by-overlay (point))))
@@ -576,6 +585,7 @@ type."
"Map all parents of TYPE to FCN. Return tags of all the types.
Argument SCOPE specify additional tags that are in scope
whose tags can be searched when needed, OR it may be a scope object."
+ (require 'semantic/analyze)
(let* (;; PARENTS specifies only the superclasses and not
;; interfaces. Inheriting from an interfaces implies
;; you have a copy of all methods locally. I think.
@@ -647,8 +657,9 @@ If POINT is not provided, then use the current location of point.
The class returned from the scope calculation is variable
`semantic-scope-cache'."
(interactive)
- (if (not (and (featurep 'semanticdb) semanticdb-current-database))
+ (if (not (and (featurep 'semantic/db) semanticdb-current-database))
nil ;; Don't do anything...
+ (require 'semantic/db-typecache)
(if (not point) (setq point (point)))
(when (interactive-p)
(semantic-fetch-tags)
@@ -714,6 +725,7 @@ The class returned from the scope calculation is variable
(semanticdb-typecache-add-dependant scopecache)
;; Handy debug output.
(when (interactive-p)
+ (require 'eieio-datadebug)
(data-debug-show scopecache)
)
;; Return ourselves
@@ -783,6 +795,7 @@ hits in order, with the first tag being in the closest scope."
;;
(defmethod semantic-analyze-show ((context semantic-scope-cache))
"Insert CONTEXT into the current buffer in a nice way."
+ (require 'semantic-analyze)
(semantic-analyze-princ-sequence (oref context scopetypes) "-> ScopeTypes: " )
(semantic-analyze-princ-sequence (oref context parents) "-> Parents: " )
(semantic-analyze-princ-sequence (oref context scope) "-> Scope: " )