changeset 104439:da5b2513c225

cedet/cedet.el (cedet-packages): Bump srecode version. cedet/data-debug.el: Require `ring' for use of ring-length. cedet/semantic.el (semantic-repeat-parse-whole-stream): Check semantic-working-type before updating progress reporter. cedet/semantic/adebug.el: Fix file header. cedet/semantic/analyze.el: eval-when-compile semantic/find, for semantic-find-tags-by-name. Declare semanticdb-strip-find-results and semanticdb-find-tags-by-name. cedet/semantic/chart.el: Require semantic/find, semantic/db-mode, semantic/db-typecache, and semantic/scope. cedet/semantic/complete.el: Declare semantic-displayor-focus-abstract-child-p function (needed as the semantic-displayor-focus-abstract class is defined only after used). Move semantic-complete-inline-custom-type and semantic-complete-inline-analyzer-displayor-class variable definitions up, before they are used, to avoid compiler warning. Require semantic/decorate, semantic/tag-file, eieio-opt, and semantic/analyze/complete. cedet/semantic/ctxt.el: Require semantic/find. Don't eval-when-compile semantic/db (semantic-get-local-variables): Use Emacs' built-in progress reporter instead of working-status-forms. cedet/semantic/db-debug.el: Require data-debug, semantic/db-mode, and semantic/format. cedet/semantic/db-ebrowse.el: Require semantic/db-mode, semantic/find, semantic/sort, data-debug (semanticdb-create-database): Require semantic/dep for semantic-add-system-include. (semanticdb-table-ebrowse, semanticdb-project-database-ebrowse): Move class definitions near top of file, before they are used, to avoid compiler warnings. (semanticdb-ebrowse-add-tree-to-table): Use split-string.
author Chong Yidong <cyd@stupidchicken.com>
date Sun, 30 Aug 2009 21:16:39 +0000
parents 33171bfc7147
children 8af937a89d62
files lisp/cedet/cedet.el lisp/cedet/data-debug.el lisp/cedet/semantic.el lisp/cedet/semantic/adebug.el lisp/cedet/semantic/analyze.el lisp/cedet/semantic/chart.el lisp/cedet/semantic/complete.el lisp/cedet/semantic/ctxt.el lisp/cedet/semantic/db-debug.el lisp/cedet/semantic/db-ebrowse.el lisp/cedet/semantic/db-find.el lisp/cedet/semantic/tag.el lisp/cedet/semantic/texi.el
diffstat 13 files changed, 134 insertions(+), 120 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/cedet/cedet.el	Sun Aug 30 21:06:53 2009 +0000
+++ b/lisp/cedet/cedet.el	Sun Aug 30 21:16:39 2009 +0000
@@ -63,7 +63,7 @@
     (cedet         ,cedet-version)
     (eieio         "1.2")
     (semantic      "2.0pre7")
-    (srecode       "0.2")
+    (srecode       "1.0pre7")
     (ede           "1.0pre7")
     (speedbar      "1.0.3"))
   "Table of CEDET packages to install.")
--- a/lisp/cedet/data-debug.el	Sun Aug 30 21:06:53 2009 +0000
+++ b/lisp/cedet/data-debug.el	Sun Aug 30 21:16:39 2009 +0000
@@ -42,6 +42,11 @@
 ;;     stuff))
 
 (require 'font-lock)
+(require 'ring)
+(require 'eieio)
+(eval-when-compile
+  (require 'semantic))
+
 ;;; Code:
 
 ;;; Compatibility
--- a/lisp/cedet/semantic.el	Sun Aug 30 21:06:53 2009 +0000
+++ b/lisp/cedet/semantic.el	Sun Aug 30 21:16:39 2009 +0000
@@ -586,19 +586,6 @@
 
 ;;;; Parse the whole system.
      ((semantic-parse-tree-needs-rebuild-p)
-      ;; (let ((working-status-dynamic-type
-      ;; 	     (if (< (point-max) semantic-minimum-working-buffer-size)
-      ;; 		 nil
-      ;; 	       working-status-dynamic-type))
-      ;; 	    (working-status-percentage-type
-      ;; 	     (if (< (point-max) semantic-minimum-working-buffer-size)
-      ;; 		 nil
-      ;; 	       working-status-percentage-type)))
-      ;; 	(working-status-forms
-      ;; 	 (semantic-parser-working-message (buffer-name)) "done"
-      ;; 	 (setq res (semantic-parse-region (point-min) (point-max)))
-      ;; 	 (working-status t)))
-
       ;; Use Emacs' built-in progress-reporter
       (let ((semantic--progress-reporter
 	     (and (>= (point-max) semantic-minimum-working-buffer-size)
@@ -737,15 +724,10 @@
       ;; Designated to ignore.
       (setq stream (car nontermsym))
       (if stream
-	  ;; (if (eq semantic-working-type 'percent)
-	  ;;     (working-status
-	  ;;      (/ (* 100 (semantic-lex-token-start (car stream)))
-	  ;; 	  (point-max)))
-	  ;;   (working-dynamic-status))
-
 	  ;; Use Emacs' built-in progress reporter:
 	  (and (boundp 'semantic--progress-reporter)
 	       semantic--progress-reporter
+	       (eq semantic-working-type 'percent)
 	       (progress-reporter-update
 		semantic--progress-reporter
 		(/ (* 100 (semantic-lex-token-start (car stream)))
--- a/lisp/cedet/semantic/adebug.el	Sun Aug 30 21:06:53 2009 +0000
+++ b/lisp/cedet/semantic/adebug.el	Sun Aug 30 21:16:39 2009 +0000
@@ -1,4 +1,4 @@
-;;; adebug.el --- Semantic Application Debugger
+;;; semantic/adebug.el --- Semantic Application Debugger
 
 ;;; Copyright (C) 2007, 2008, 2009 Free Software Foundation, Inc.
 
@@ -420,4 +420,4 @@
 
 (provide 'semantic/adebug)
 
-;;; semantic-adebug.el ends here
+;;; semantic/adebug.el ends here
--- a/lisp/cedet/semantic/analyze.el	Sun Aug 30 21:06:53 2009 +0000
+++ b/lisp/cedet/semantic/analyze.el	Sun Aug 30 21:16:39 2009 +0000
@@ -1,4 +1,4 @@
-;;; analyze.el --- Analyze semantic tags against local context
+;;; semantic/analyze.el --- Analyze semantic tags against local context
 
 ;;; Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2007, 2008, 2009
 ;;; Free Software Foundation, Inc.
@@ -65,19 +65,19 @@
 ;;       other possible completions.
 ;;
 (require 'eieio)
-;; (require 'inversion)
-;; (eval-and-compile
-;;   (inversion-require 'eieio "1.0"))
 (require 'semantic)
 (require 'semantic/format)
 (require 'semantic/ctxt)
 (require 'semantic/sort)
-(eval-when-compile (require 'semantic/db)
-		   (require 'semantic/db-find))
-
+(eval-when-compile (require 'semantic/find))
 (require 'semantic/scope)
 (require 'semantic/analyze/fcn)
 
+;; `semanticdb-typecache-find' autoloads from semantic/db-typecache,
+;; which requires semantic/db-find.
+(declare-function semanticdb-strip-find-results "semantic/db-find")
+(declare-function semanticdb-find-tags-by-name "semantic/db-find")
+
 ;;; Code:
 (defvar semantic-analyze-error-stack nil
   "Collection of any errors thrown during analysis.")
@@ -684,8 +684,11 @@
 ;;
 ;; Friendly output of a context analysis.
 ;;
+(declare-function pulse-momentary-highlight-region "pulse")
+
 (defmethod semantic-analyze-pulse ((context semantic-analyze-context))
   "Pulse the region that CONTEXT affects."
+  (require 'pulse)
   (save-excursion
     (set-buffer (oref context :buffer))
     (let ((bounds (oref context :bounds)))
@@ -766,4 +769,4 @@
 
 (provide 'semantic/analyze)
 
-;;; semantic-analyze.el ends here
+;;; semantic/analyze.el ends here
--- a/lisp/cedet/semantic/chart.el	Sun Aug 30 21:06:53 2009 +0000
+++ b/lisp/cedet/semantic/chart.el	Sun Aug 30 21:16:39 2009 +0000
@@ -1,4 +1,4 @@
-;;; chart.el --- Utilities for use with semantic tag tables
+;;; semantic/chart.el --- Utilities for use with semantic tag tables
 
 ;;; Copyright (C) 1999, 2000, 2001, 2003, 2005, 2008, 2009
 ;;; Free Software Foundation, Inc.
@@ -26,8 +26,12 @@
 ;; the output of the semantic parser.
 ;;
 
+(require 'chart)
 (require 'semantic)
-(require 'chart)
+(require 'semantic/find)
+(require 'semantic/db-mode)
+(require 'semantic/db-typecache)
+(require 'semantic/scope)
 
 ;;; Code:
 
@@ -164,4 +168,4 @@
 
 (provide 'semantic/chart)
 
-;;; semantic-chart.el ends here
+;;; semantic/chart.el ends here
--- a/lisp/cedet/semantic/complete.el	Sun Aug 30 21:06:53 2009 +0000
+++ b/lisp/cedet/semantic/complete.el	Sun Aug 30 21:16:39 2009 +0000
@@ -1,4 +1,4 @@
-;;; complete.el --- Routines for performing tag completion
+;;; semantic/complete.el --- Routines for performing tag completion
 
 ;;; Copyright (C) 2003, 2004, 2005, 2007, 2008, 2009
 ;;; Free Software Foundation, Inc.
@@ -108,15 +108,19 @@
 ;; a buffer.
 
 (require 'eieio)
-(require 'semantic/tag)
+(require 'eieio-opt)
+(require 'semantic/tag-file)
 (require 'semantic/find)
 (require 'semantic/analyze)
 (require 'semantic/format)
 (require 'semantic/ctxt)
 ;; Keep semanticdb optional.
-(eval-when-compile
-  (require 'semantic/db)
-  (require 'semantic/db-find))
+;; (eval-when-compile
+;;   (require 'semantic/db)
+;;   (require 'semantic/db-find))
+(require 'semantic/decorate)
+(require 'semantic/analyze/complete)
+
 
 (eval-when-compile
   (condition-case nil
@@ -325,6 +329,11 @@
 (defvar semantic-complete-current-matched-tag nil
   "Variable used to pass the tags being matched to the prompt.")
 
+;; semantic-displayor-focus-abstract-child-p is part of the
+;; semantic-displayor-focus-abstract class, defined later in this
+;; file.
+(declare-function semantic-displayor-focus-abstract-child-p "semantic/complete")
+
 (defun semantic-complete-current-match ()
   "Calculate a match from the current completion environment.
 Save this in our completion variable.  Make sure that variable
@@ -1759,6 +1768,29 @@
 ;;; ------------------------------------------------------------
 ;;; Specific queries
 ;;
+(defvar semantic-complete-inline-custom-type
+  (append '(radio)
+	  (mapcar
+	   (lambda (class)
+	     (let* ((C (intern (car class)))
+		    (doc (documentation-property C 'variable-documentation))
+		    (doc1 (car (split-string doc "\n")))
+		    )
+	       (list 'const
+		     :tag doc1
+		     C)))
+	   (eieio-build-class-alist semantic-displayor-abstract t))
+	  )
+  "Possible options for inlince completion displayors.
+Use this to enable custom editing.")
+
+(defcustom semantic-complete-inline-analyzer-displayor-class
+  'semantic-displayor-traditional
+  "*Class for displayor to use with inline completion."
+  :group 'semantic
+  :type semantic-complete-inline-custom-type
+  )
+
 (defun semantic-complete-read-tag-buffer-deep (prompt &optional
 						      default-tag
 						      initial-input
@@ -1885,30 +1917,6 @@
      inp
      history)))
 
-(defvar semantic-complete-inline-custom-type
-  (append '(radio)
-	  (mapcar
-	   (lambda (class)
-	     (let* ((C (intern (car class)))
-		    (doc (documentation-property C 'variable-documentation))
-		    (doc1 (car (split-string doc "\n")))
-		    )
-	       (list 'const
-		     :tag doc1
-		     C)))
-	   (eieio-build-class-alist semantic-displayor-abstract t))
-	  )
-  "Possible options for inlince completion displayors.
-Use this to enable custom editing.")
-
-(defcustom semantic-complete-inline-analyzer-displayor-class
-  'semantic-displayor-traditional
-  "*Class for displayor to use with inline completion."
-  :group 'semantic
-  :type semantic-complete-inline-custom-type
-  )
-
-
 (defun semantic-complete-inline-analyzer (context)
   "Complete a symbol name by name based on the current context.
 This is similar to `semantic-complete-read-tag-analyze', except
@@ -2125,4 +2133,4 @@
 ;; End
 (provide 'semantic/complete)
 
-;;; semantic-complete.el ends here
+;;; semantic/complete.el ends here
--- a/lisp/cedet/semantic/ctxt.el	Sun Aug 30 21:06:53 2009 +0000
+++ b/lisp/cedet/semantic/ctxt.el	Sun Aug 30 21:16:39 2009 +0000
@@ -1,4 +1,4 @@
-;;; ctxt.el --- Context calculations for Semantic tools.
+;;; semantic/ctxt.el --- Context calculations for Semantic tools.
 
 ;;; Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
 ;;; 2007, 2008, 2009 Free Software Foundation, Inc.
@@ -31,7 +31,7 @@
 ;; the current context is calculated.
 ;;
 (require 'semantic)
-(eval-when-compile (require 'semantic/db))
+(require 'semantic/find)
 
 ;;; Code:
 (defvar semantic-command-separation-character
@@ -155,16 +155,15 @@
 Local variables are returned in Semantic tag format.
 This can be overriden with `get-local-variables'."
   ;; The working status is to let the parser work properly
-  (working-status-forms
-   (semantic-parser-working-message "Local")
-   "done"
-   (save-excursion
-     (if point (goto-char point))
-     (let* ((semantic-working-type nil)
-	    ;; Disable parsing messages
-	    (working-status-dynamic-type nil)
-	    (case-fold-search semantic-case-fold))
-       (:override-with-args ())))))
+  (let ((semantic--progress-reporter
+	 (make-progress-reporter (semantic-parser-working-message "Local")
+				 0 100)))
+    (save-excursion
+      (if point (goto-char point))
+      (let* ((semantic-working-type nil)
+	     ;; Disable parsing messages
+	     (case-fold-search semantic-case-fold))
+	(:override-with-args ())))))
 
 (defun semantic-get-local-variables-default ()
   "Get local values from a specific context.
@@ -610,4 +609,4 @@
 
 (provide 'semantic/ctxt)
 
-;;; semantic-ctxt.el ends here
+;;; semantic/ctxt.el ends here
--- a/lisp/cedet/semantic/db-debug.el	Sun Aug 30 21:06:53 2009 +0000
+++ b/lisp/cedet/semantic/db-debug.el	Sun Aug 30 21:16:39 2009 +0000
@@ -1,4 +1,4 @@
-;;; db-debug.el --- Extra level debugging routines for Semantic
+;;; semantic/db-debug.el --- Extra level debugging routines for Semantic
 
 ;;; Copyright (C) 2008, 2009 Free Software Foundation, Inc.
 
@@ -24,7 +24,10 @@
 ;; Various routines for debugging SemanticDB issues, or viewing
 ;; semanticdb state.
 
+(require 'data-debug)
 (require 'semantic/db)
+(require 'semantic/db-mode)
+(require 'semantic/format)
 
 ;;; Code:
 ;;
@@ -105,4 +108,5 @@
 
 
 (provide 'semantic/db-debug)
-;;; semanticdb-debug.el ends here
+
+;;; semantic/db-debug.el ends here
--- a/lisp/cedet/semantic/db-ebrowse.el	Sun Aug 30 21:06:53 2009 +0000
+++ b/lisp/cedet/semantic/db-ebrowse.el	Sun Aug 30 21:16:39 2009 +0000
@@ -1,4 +1,4 @@
-;;; db-ebrowse.el --- Semanticdb backend using ebrowse.
+;;; semantic/db-ebrowse.el --- Semanticdb backend using ebrowse.
 
 ;;; Copyright (C) 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
 
@@ -56,6 +56,12 @@
   (require 'eieio-opt)
   )
 (require 'semantic/db-file)
+(require 'semantic/db-mode)
+(require 'semantic/find)
+(require 'semantic/sort)
+(require 'data-debug)
+
+(declare-function semantic-add-system-include "semantic/dep")
 
 (eval-and-compile
   ;; Hopefully, this will allow semanticdb-ebrowse to compile under
@@ -77,6 +83,41 @@
   :group 'semanticdb
   :type 'string)
 
+;;; SEMANTIC Database related Code
+;;; Classes:
+(defclass semanticdb-table-ebrowse (semanticdb-table)
+  ((major-mode :initform c++-mode)
+   (ebrowse-tree :initform nil
+		 :initarg :ebrowse-tree
+		 :documentation
+		 "The raw ebrowse tree for this file."
+		 )
+   (global-extract :initform nil
+		   :initarg :global-extract
+		   :documentation
+		   "Table of ebrowse tags specific to this file.
+This table is compisited from the ebrowse *Globals* section.")
+   )
+  "A table for returning search results from ebrowse.")
+
+(defclass semanticdb-project-database-ebrowse
+  (semanticdb-project-database)
+  ((new-table-class :initform semanticdb-table-ebrowse
+		    :type class
+		    :documentation
+		    "New tables created for this database are of this class.")
+   (system-include-p :initform nil
+		     :initarg :system-include
+		     :documentation
+		     "Flag indicating this database represents a system include directory.")
+   (ebrowse-struct :initform nil
+		   :initarg :ebrowse-struct
+		   )
+   )
+  "Semantic Database deriving tags using the EBROWSE tool.
+EBROWSE is a C/C++ parser for use with `ebrowse' Emacs program.")
+
+
 (defun semanticdb-ebrowse-C-file-p (file)
   "Is FILE a C or C++ file?"
   (or (string-match semanticdb-ebrowse-file-match file)
@@ -187,40 +228,6 @@
 	    (delete-file BFLB))
 	  )))))
 
-;;; SEMANTIC Database related Code
-;;; Classes:
-(defclass semanticdb-table-ebrowse (semanticdb-table)
-  ((major-mode :initform c++-mode)
-   (ebrowse-tree :initform nil
-		 :initarg :ebrowse-tree
-		 :documentation
-		 "The raw ebrowse tree for this file."
-		 )
-   (global-extract :initform nil
-		   :initarg :global-extract
-		   :documentation
-		   "Table of ebrowse tags specific to this file.
-This table is compisited from the ebrowse *Globals* section.")
-   )
-  "A table for returning search results from ebrowse.")
-
-(defclass semanticdb-project-database-ebrowse
-  (semanticdb-project-database)
-  ((new-table-class :initform semanticdb-table-ebrowse
-		    :type class
-		    :documentation
-		    "New tables created for this database are of this class.")
-   (system-include-p :initform nil
-		     :initarg :system-include
-		     :documentation
-		     "Flag indicating this database represents a system include directory.")
-   (ebrowse-struct :initform nil
-		   :initarg :ebrowse-struct
-		   )
-   )
-  "Semantic Database deriving tags using the EBROWSE tool.
-EBROWSE is a C/C++ parser for use with `ebrowse' Emacs program.")
-
 ;JAVE this just instantiates a default empty ebrowse struct?
 ; how would new instances wind up here?
 ; the ebrowse class isnt singleton, unlike the emacs lisp one
@@ -292,6 +299,7 @@
 If there is no database for DIRECTORY available, then
 {not implemented yet} create one.  Return nil if that is not possible."
   ;; MAKE SURE THAT THE FILE LOADED DOESN'T ALREADY EXIST.
+  (require 'semantic/dep)
   (let ((dbs semanticdb-database-list)
 	(found nil))
     (while (and (not found) dbs)
@@ -425,7 +433,7 @@
 		  (semanticdb-create-table dbe fname)))
 	 (class (ebrowse-ts-class tree))
 	 (scope (ebrowse-cs-scope class))
-	 (ns (when scope (cedet-split-string scope ":" t)))
+	 (ns (when scope (split-string scope ":" t)))
 	 (nst nil)
 	 (cls nil)
 	 )
@@ -703,4 +711,4 @@
 
 (provide 'semantic/db-ebrowse)
 
-;;; semanticdb-ebrowse.el ends here
+;;; semantic/db-ebrowse.el ends here
--- a/lisp/cedet/semantic/db-find.el	Sun Aug 30 21:06:53 2009 +0000
+++ b/lisp/cedet/semantic/db-find.el	Sun Aug 30 21:16:39 2009 +0000
@@ -1,4 +1,4 @@
-;;; db-find.el --- Searching through semantic databases.
+;;; semantic/db-find.el --- Searching through semantic databases.
 
 ;;; Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
 ;;; 2008, 2009 Free Software Foundation, Inc.
@@ -1350,4 +1350,4 @@
 
 (provide 'semantic/db-find)
 
-;;; semanticdb-find.el ends here
+;;; semantic/db-find.el ends here
--- a/lisp/cedet/semantic/tag.el	Sun Aug 30 21:06:53 2009 +0000
+++ b/lisp/cedet/semantic/tag.el	Sun Aug 30 21:16:39 2009 +0000
@@ -63,7 +63,7 @@
 (declare-function semantic-format-tag-summarize "semantic/format")
 (declare-function semantic-format-tag-name "semantic/format")
 
-(defconst semantic-tag-version semantic-version
+(defconst semantic-tag-version "2.0pre7"
   "Version string of semantic tags made with this code.")
 
 (defconst semantic-tag-incompatible-version "1.0"
--- a/lisp/cedet/semantic/texi.el	Sun Aug 30 21:06:53 2009 +0000
+++ b/lisp/cedet/semantic/texi.el	Sun Aug 30 21:16:39 2009 +0000
@@ -35,9 +35,10 @@
   (require 'semantic/db)
   (require 'semantic/db-find)
   (require 'semantic/ctxt)
-  (require 'semantic/imenu)
+;;  (require 'semantic/imenu)
   (require 'semantic/doc)
-  (require 'senator))
+;;  (require 'senator)
+)
 
 (defvar semantic-texi-super-regex
   "^@\\(top\\|chapter\\|\\(sub\\)*section\\|unnumbered\\(\\(sub\\)*sec\\)?\\|\