Function: semantic-complete-self-insert
semantic-complete-self-insert is an autoloaded, interactive and
byte-compiled function defined in complete.el.gz.
Signature
(semantic-complete-self-insert ARG)
Documentation
Like self-insert-command, but does completion afterwards.
ARG is passed to self-insert-command. If ARG is nil,
use semantic-complete-analyze-inline to complete.
Key Bindings
Source Code
;; Defined in /usr/src/emacs/lisp/cedet/semantic/complete.el.gz
;;;###autoload
(defun semantic-complete-self-insert (arg)
"Like `self-insert-command', but does completion afterwards.
ARG is passed to `self-insert-command'. If ARG is nil,
use `semantic-complete-analyze-inline' to complete."
(interactive "p")
;; If we are already in a completion scenario, exit now, and then start over.
(semantic-complete-inline-exit)
;; Insert the key
(self-insert-command arg)
;; Prepare for doing completion, but exit quickly if there is keyboard
;; input.
(when (save-window-excursion
(save-excursion
;; FIXME: Use `while-no-input'?
(and (not (semantic-exit-on-input 'csi
(semantic-fetch-tags)
(semantic-throw-on-input 'csi)
nil))
(= arg 1)
(not (semantic-exit-on-input 'csi
(semantic-analyze-current-context)
(semantic-throw-on-input 'csi)
nil)))))
(condition-case nil
(semantic-complete-analyze-inline)
;; Ignore errors. Seems likely that we'll get some once in a while.
(error nil))
))