Commit 1fe1547a authored by Chong Yidong's avatar Chong Yidong
Browse files

lisp/cedet/semantic/db-ref.el: Require semantic/db.

(semanticdb-add-reference): Fix feature name.
(semanticdb-ref-test): Require eieio-datadebug instead of data-debug.

lisp/cedet/semantic/analyze/debug.el: Fix file header.

lisp/cedet/semantic/analyze/refs.el: Add local vars for autoloading.
Require semantic, semantic/analyze, and semantic/db-find.
Declare external functions.
(semantic-analyze-proto-impl-toggle): Autoload.  Require
semantic/decorate.
(semantic-analyze-current-tag): Autoload.

lisp/cedet/semantic/bovine/c.el: Declare external function.

lisp/cedet/semantic/bovine/gcc.el: Add local vars for autoloading.
(semantic-gcc-setup): Autoload.

lisp/cedet/semantic/decorate/include.el: Declare external functions.

lisp/cedet/semantic/symref/cscope.el: Declare external functions.

lisp/cedet/semantic/symref/filter.el: Declare external functions.

lisp/cedet/semantic/symref/list.el (semantic-symref-rb-goto-file)
(semantic-symref-rb-goto-tag, semantic-symref-rb-goto-match): Use
last-command-event.
(semantic-symref, semantic-symref-symbol): Autoload.
parent a4556861
......@@ -32,6 +32,8 @@
;; For semantic-find-tags-by-class:
(eval-when-compile (require 'semantic/find))
(declare-function ede-get-locator-object "ede/files")
;;; Code:
(defun semantic-analyze-debug-assist ()
......@@ -399,12 +401,13 @@ or implementing a version specific to ")
(edeobj
(save-excursion
(set-buffer (semanticdb-get-buffer table))
ede-object))
(and (boundp 'ede-object)
ede-object)))
(edeproj
(save-excursion
(set-buffer (semanticdb-get-buffer table))
ede-object-project))
)
(and (boundp 'ede-object-project)
ede-object-project))))
(princ "\n\nInclude Path Summary:")
(when edeobj
......
......@@ -34,6 +34,15 @@
;; Once the raw data is available, queries for impl, prototype, or
;; perhaps other things become cheap.
(require 'semantic)
(require 'semantic/analyze)
(require 'semantic/db-find)
(eval-when-compile (require 'semantic/find))
(declare-function data-debug-new-buffer "data-debug")
(declare-function data-debug-insert-object-slots "eieio-datadebug")
(declare-function semantic-momentary-highlight-tag "semantic/decorate")
;;; Code:
(defclass semantic-analyze-references ()
((tag :initarg :tag
......@@ -270,6 +279,7 @@ Only works for tags in the global namespace."
;;; USER COMMANDS
;;
;;;###autoload
(defun semantic-analyze-current-tag ()
"Analyze the tag under point."
(interactive)
......@@ -281,13 +291,16 @@ Only works for tags in the global namespace."
(message "Analysis took %.2f seconds." (semantic-elapsed-time start end))
(if sac
(progn
(require 'eieio-datadebug)
(data-debug-new-buffer "*Analyzer Reference ADEBUG*")
(data-debug-insert-object-slots sac "]"))
(message "No Context to analyze here."))))
;;;###autoload
(defun semantic-analyze-proto-impl-toggle ()
"Toggle between the implementation, and a prototype of tag under point."
(interactive)
(require 'semantic/decorate)
(semantic-fetch-tags)
(let* ((tag (semantic-current-tag))
(sar (if tag
......@@ -312,4 +325,10 @@ Only works for tags in the global namespace."
(provide 'semantic/analyze/refs)
;; Local variables:
;; generated-autoload-file: "../loaddefs.el"
;; generated-autoload-feature: semantic/loaddefs
;; generated-autoload-load-name: "semantic/analyze/refs"
;; End:
;;; semantic/analyze/refs.el ends here
......@@ -44,6 +44,7 @@
(declare-function semanticdb-file-table-object "semantic/db")
(declare-function semanticdb-needs-refresh-p "semantic/db")
(declare-function c-forward-conditional "cc-cmds")
(declare-function ede-system-include-path "ede")
;;; Compatibility
;;
......@@ -1645,7 +1646,7 @@ DO NOT return the list of tags encompassing point."
)
(princ "\n\nInclude Path Summary:\n")
(when ede-object
(when (and (boundp 'ede-object) ede-object)
(princ "\n This file's project include is handled by:\n")
(princ " ")
(princ (object-print ede-object))
......
......@@ -26,6 +26,8 @@
(require 'semantic/dep)
(defvar semantic-lex-c-preprocessor-symbol-file)
(defvar semantic-lex-c-preprocessor-symbol-map)
(declare-function semantic-c-reset-preprocessor-symbol-map
"semantic/bovine/gcc")
......@@ -142,6 +144,7 @@ This is an alist, and should include keys of:
'--prefix - Where GCC was installed.
It should also include other symbols GCC was compiled with.")
;;;###autoload
(defun semantic-gcc-setup ()
"Setup Semantic C/C++ parsing based on GCC output."
(interactive)
......@@ -316,4 +319,11 @@ gcc version 2.95.2 19991024 (release)"
)
(provide 'semantic/bovine/gcc)
;; Local variables:
;; generated-autoload-file: "../loaddefs.el"
;; generated-autoload-feature: semantic/loaddefs
;; generated-autoload-load-name: "semantic/bovine/gcc"
;; End:
;;; semantic/bovine/gcc.el ends here
......@@ -38,6 +38,7 @@
;;; Code:
(require 'eieio)
(require 'semantic)
(require 'semantic/db)
(require 'semantic/tag)
(defvar semanticdb-find-default-throttle)
......@@ -55,7 +56,7 @@ will be added to the database that INCLUDE-TAG refers to."
;; NOTE: I should add a check to make sure include-tag is in DB.
;; but I'm too lazy.
(let* ((semanticdb-find-default-throttle
(if (featurep 'semanticdb-find)
(if (featurep 'semantic/db-find)
(remq 'unloaded semanticdb-find-default-throttle)
nil))
(refdbt (semanticdb-find-table-for-include include-tag dbt))
......@@ -150,14 +151,14 @@ DBT, the second argument is DBT."
(defvar semanticdb-current-table)
(declare-function data-debug-new-buffer "data-debug")
(declare-function data-debug-insert-object-slots "data-debug")
(declare-function data-debug-insert-object-slots "eieio-datadebug")
(defun semanticdb-ref-test (refresh)
"Dump out the list of references for the current buffer.
If REFRESH is non-nil, cause the current table to have it's references
refreshed before dumping the result."
(interactive "p")
(require 'data-debug)
(require 'eieio-datadebug)
;; If we need to refresh... then do so.
(when refresh
(semanticdb-refresh-references semanticdb-current-table))
......
......@@ -36,6 +36,8 @@
(require 'semantic/find))
(defvar semantic-dependency-system-include-path)
(declare-function ede-get-locator-object "ede/files")
(declare-function ede-system-include-path "ede/cpp-root")
;;; Code:
......@@ -623,7 +625,9 @@ Argument EVENT describes the event that caused this function to be called."
)
(princ "\nInclude Path Summary:\n\n")
(when ede-object
(when (and (boundp 'ede-object)
(boundp 'ede-object-project)
ede-object)
(princ " This file's project include search is handled by the EDE object:\n")
(princ " Buffer Target: ")
(princ (object-print ede-object))
......
......@@ -26,6 +26,10 @@
(require 'cedet-cscope)
(require 'semantic/symref)
(defvar ede-minor-mode)
(declare-function ede-toplevel "ede/files")
(declare-function ede-project-root-directory "ede/files")
;;; Code:
(defclass semantic-symref-tool-cscope (semantic-symref-tool-baseclass)
(
......
......@@ -34,6 +34,11 @@
;;; Code:
(require 'semantic)
(declare-function srecode-active-template-region "srecode/fields")
(declare-function srecode-delete "srecode/fields")
(declare-function srecode-field "srecode/fields")
(declare-function srecode-template-inserted-region "srecode/fields")
(declare-function srecode-overlaid-activate "srecode/fields")
;;; FILTERS
;;
......@@ -123,7 +128,7 @@ Depends on the SRecode Field editing API."
;; I think we're good for this example. Give it a go through
;; our fancy interface from SRecode.
(require 'srecode-fields)
(require 'srecode/fields)
;; Make sure there is nothing active.
(let ((ar (srecode-active-template-region)))
......
......@@ -38,6 +38,7 @@
;;; Code:
;;;###autoload
(defun semantic-symref ()
"Find references to the current tag.
This command uses the currently configured references tool within the
......@@ -60,6 +61,7 @@ Display the references in`semantic-symref-results-mode'"
(setq res (semantic-symref-find-references-by-name (semantic-tag-name ct)))
(semantic-symref-produce-list-on-results res (semantic-tag-name ct))))
;;;###autoload
(defun semantic-symref-symbol (sym)
"Find references to the symbol SYM.
This command uses the currently configured references tool within the
......@@ -276,7 +278,7 @@ BUTTON is the button that was clicked."
)
(switch-to-buffer-other-window buff)
(pulse-momentary-highlight-one-line (point))
(when (eq last-command-char ? ) (select-window win))
(when (eq last-command-event ?\s) (select-window win))
))
......@@ -291,7 +293,7 @@ BUTTON is the button that was clicked."
(switch-to-buffer-other-window buff)
(semantic-go-to-tag tag)
(pulse-momentary-highlight-one-line (point))
(when (eq last-command-char ? ) (select-window win))
(when (eq last-command-event ?\s) (select-window win))
)
)
......@@ -305,9 +307,9 @@ BUTTON is the button that was clicked."
(win (selected-window))
)
(switch-to-buffer-other-window buff)
(goto-line line)
(with-no-warnings (goto-line line))
(pulse-momentary-highlight-one-line (point))
(when (eq last-command-char ? ) (select-window win))
(when (eq last-command-event ?\s) (select-window win))
)
)
......@@ -325,4 +327,10 @@ BUTTON is the button that was clicked."
(provide 'semantic/symref/list)
;; Local variables:
;; generated-autoload-file: "../loaddefs.el"
;; generated-autoload-feature: semantic/loaddefs
;; generated-autoload-load-name: "semantic/symref/list"
;; End:
;;; semantic/symref/list.el ends here
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment