changeset 104456:6065d66f0c99

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.
author Chong Yidong <cyd@stupidchicken.com>
date Sat, 05 Sep 2009 23:04:46 +0000
parents d66016869489
children 724ff52eda98
files lisp/cedet/semantic/analyze/debug.el lisp/cedet/semantic/analyze/refs.el lisp/cedet/semantic/bovine/c.el lisp/cedet/semantic/bovine/gcc.el lisp/cedet/semantic/db-ref.el lisp/cedet/semantic/decorate/include.el lisp/cedet/semantic/symref/cscope.el lisp/cedet/semantic/symref/filter.el lisp/cedet/semantic/symref/list.el
diffstat 9 files changed, 68 insertions(+), 13 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/cedet/semantic/analyze/debug.el	Sat Sep 05 21:20:17 2009 +0000
+++ b/lisp/cedet/semantic/analyze/debug.el	Sat Sep 05 23:04:46 2009 +0000
@@ -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 @@
 	(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
--- a/lisp/cedet/semantic/analyze/refs.el	Sat Sep 05 21:20:17 2009 +0000
+++ b/lisp/cedet/semantic/analyze/refs.el	Sat Sep 05 23:04:46 2009 +0000
@@ -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 @@
 
 ;;; USER COMMANDS
 ;;
+;;;###autoload
 (defun semantic-analyze-current-tag ()
   "Analyze the tag under point."
   (interactive)
@@ -281,13 +291,16 @@
     (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 @@
 
 (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
--- a/lisp/cedet/semantic/bovine/c.el	Sat Sep 05 21:20:17 2009 +0000
+++ b/lisp/cedet/semantic/bovine/c.el	Sat Sep 05 23:04:46 2009 +0000
@@ -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 @@
 	)
 
       (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))
--- a/lisp/cedet/semantic/bovine/gcc.el	Sat Sep 05 21:20:17 2009 +0000
+++ b/lisp/cedet/semantic/bovine/gcc.el	Sat Sep 05 23:04:46 2009 +0000
@@ -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 @@
   '--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 @@
   )
 
 (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
--- a/lisp/cedet/semantic/db-ref.el	Sat Sep 05 21:20:17 2009 +0000
+++ b/lisp/cedet/semantic/db-ref.el	Sat Sep 05 23:04:46 2009 +0000
@@ -38,6 +38,7 @@
 ;;; Code:
 (require 'eieio)
 (require 'semantic)
+(require 'semantic/db)
 (require 'semantic/tag)
 
 (defvar semanticdb-find-default-throttle)
@@ -55,7 +56,7 @@
   ;; 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 @@
 
 (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))
--- a/lisp/cedet/semantic/decorate/include.el	Sat Sep 05 21:20:17 2009 +0000
+++ b/lisp/cedet/semantic/decorate/include.el	Sat Sep 05 23:04:46 2009 +0000
@@ -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 @@
 	)
 
       (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))
--- a/lisp/cedet/semantic/symref/cscope.el	Sat Sep 05 21:20:17 2009 +0000
+++ b/lisp/cedet/semantic/symref/cscope.el	Sat Sep 05 23:04:46 2009 +0000
@@ -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)
   (
--- a/lisp/cedet/semantic/symref/filter.el	Sat Sep 05 21:20:17 2009 +0000
+++ b/lisp/cedet/semantic/symref/filter.el	Sat Sep 05 23:04:46 2009 +0000
@@ -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 @@
 
     ;; 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)))
--- a/lisp/cedet/semantic/symref/list.el	Sat Sep 05 21:20:17 2009 +0000
+++ b/lisp/cedet/semantic/symref/list.el	Sat Sep 05 23:04:46 2009 +0000
@@ -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 @@
     (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 @@
 	 )
     (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 @@
     (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 @@
 	 (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 @@
 
 (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