.emacs-my
changeset 626 a759aa107534
parent 625 78017f6d5b43
child 627 a64819b490c3
--- a/.emacs-my	Tue Apr 05 13:54:38 2011 +0300
+++ b/.emacs-my	Thu Apr 07 18:37:31 2011 +0300
@@ -1232,10 +1232,12 @@
 ;; For debug use 'semantic-debug-idle-function' and 'semantic-debug-idle-work-function'.
 
 (unless (featurep 'cedet)
-  ;; (when (or (and (= emacs-major-version 23) (= emacs-minor-version 2)) (>= emacs-minor-version 24))
-  ;;   (semantic-mode 1)
-  ;;   )
-  )
+  (when (or
+         (and (= emacs-major-version 23) (>= emacs-minor-version 2))
+         (>= emacs-minor-version 24)
+         )
+    (semantic-mode 1)
+    ) )
 
 (when (featurep 'cedet)
   (unless (equal cedet-version "1.0pre7") ; Come with Emacs 23.2.
@@ -1260,21 +1262,20 @@
   ;; (setq semantic-idle-work-parse-neighboring-files-flag nil)
 
   ;; semantic-dependency-system-include-path, semantic-customize-system-include-path
-  (setq-mode-local c-mode semanticdb-find-default-throttle '(project unloaded system recursive))
+
+  ;; file local project unloaded system recursive
+  (setq-mode-local c-mode semanticdb-find-default-throttle '(file))
   (add-hook 'c-mode-hook (lambda nil (semantic-add-system-include "~/.emacs.d/include" 'c-mode)))
   (add-hook 'c-mode-hook (lambda nil (semantic-add-system-include "~/.emacs.d/include" 'c++-mode)))
   (global-semanticdb-minor-mode 1)
 
-  (unless (equal cedet-version "1.0pre7") ; Come with Emacs 23.2.
-    (require 'ede-locate)
-    (when (cedet-idutils-version-check t)
-      (add-to-list 'ede-locate-setup-options 'ede-locate-idutils)
-      )
-    (when (cedet-gnu-global-version-check t)
-      (add-to-list 'ede-locate-setup-options 'ede-locate-global)
-      (semanticdb-enable-gnu-global-databases 'c-mode)
-      (semanticdb-enable-gnu-global-databases 'c++-mode)
-      )
+  ;; (add-to-list 'ede-locate-setup-options 'ede-locate-idutils)
+  ;; (add-to-list 'ede-locate-setup-options 'ede-locate-global)
+
+  (ignore-errors (require 'cedet-idutils))
+  (when (ignore-errors (require 'cedet-global))
+    (semanticdb-enable-gnu-global-databases 'c-mode)
+    (semanticdb-enable-gnu-global-databases 'c++-mode)
     )
 
   (global-set-key (kbd "C-c , .") 'semantic-ia-fast-jump)