no autocomplete with cedet 1.1 in command line emacs

145 views Asked by At

I'm trying to use cedet 1.1 in emacs 23. As far as I can tell I have installed it and when I load up emacs it loads cedet, but i'm using emacs with the -nw option. When I type . or -> i'm not getting any code completetion. (c++ file, on an std::vector object). So for example, when I type:

vec_map.

or

vec_map->

does nothing, where vec_map is an instance of std::vector.

I'm assuming its possible to have code completion in the command line version of emacs.

Also, my .emacs file is (and it loads just fine):

(load-file "~/cedet-1.1/common/cedet.el")
(global-ede-mode 1)                      ; Enable the Project management system
(semantic-load-enable-code-helpers)      ; Enable prototype help and smart completion
(global-srecode-minor-mode 1)            ; Enable template insertion menu
1

There are 1 answers

0
Alex Ott On

By default, auto-completion in CEDET should be either explicitly called via semantic-ia-complete-symbol-menu or semantic-ia-complete-symbol commands, or you should configure completion on self-insert via:

(defun my/c-mode-cedet-hook ()
  (local-set-key "." 'semantic-complete-self-insert)
  (local-set-key ">" 'semantic-complete-self-insert)
)
(add-hook 'c-mode-common-hook 'my/c-mode-cedet-hook)

But as mentioned in comments, it's better to take latest Emacs and/or CEDET from bzr - there were many errors fixed since 1.1 release.