Describe project macro symbols.
* cedet/semantic/complete.el (semantic-complete-do-completion):
Don't call semantic-collector-current-exact-match.
* cedet/ede.el (ede-apply-preprocessor-map): Accept lists of
ede-objects as targets.
* cedet/ede/pmake.el (ede-proj-makefile-insert-variables): Output
a target's object list even if compiler vars are already in the
Makefile.
* cedet/ede/emacs.el (ede-preprocessor-map): Add config.h to the
list of headers producing necessary macros.
+2009-12-05 Eric Ludlam <zappo@gnu.org>
+
+ * cedet/semantic/bovine/c.el (semantic-c-describe-environment):
+ Describe project macro symbols.
+
+ * cedet/semantic/complete.el (semantic-complete-do-completion):
+ Don't call semantic-collector-current-exact-match.
+
+ * cedet/ede.el (ede-apply-preprocessor-map): Accept lists of
+ ede-objects as targets.
+
+ * cedet/ede/pmake.el (ede-proj-makefile-insert-variables): Output
+ a target's object list even if compiler vars are already in the
+ Makefile.
+
+ * cedet/ede/emacs.el (ede-preprocessor-map): Add config.h to the
+ list of headers producing necessary macros.
+
2009-12-05 Roland Winkler <Roland.Winkler@physik.uni-erlangen.de>
* textmodes/bibtex.el (bibtex-map-entries): Use marker to keep
(defun ede-apply-preprocessor-map ()
"Apply preprocessor tables onto the current buffer."
(when (and ede-object (boundp 'semantic-lex-spp-macro-symbol-obarray))
- (let ((map (ede-preprocessor-map ede-object)))
+ (let* ((objs ede-object)
+ (map (ede-preprocessor-map (if (consp objs)
+ (car objs)
+ objs))))
(when map
;; We can't do a require for the below symbol.
(setq semantic-lex-spp-macro-symbol-obarray
- (semantic-lex-make-spp-table map))
- ))))
+ (semantic-lex-make-spp-table map)))
+ (when (consp objs)
+ (message "Choosing preprocessor syms for project %s"
+ (object-name (car objs)))))))
(defmethod ede-system-include-path ((this ede-project))
"Get the system include path used by project THIS."
(root (ede-project-root proj))
(table (semanticdb-file-table-object
(ede-expand-filename root "lisp.h")))
+ (config (semanticdb-file-table-object
+ (ede-expand-filename root "config.h")))
filemap
)
(when table
(semanticdb-refresh-table table))
(setq filemap (append filemap (oref table lexical-table)))
)
+ (when config
+ (when (semanticdb-needs-refresh-p config)
+ (semanticdb-refresh-table config))
+ (setq filemap (append filemap (oref config lexical-table)))
+ )
filemap
))
(src (oref this source)))
(while comp
(ede-compiler-only-once (car comp)
- (ede-proj-makefile-insert-object-variables (car comp) name src)
(ede-proj-makefile-insert-variables (car comp)))
(setq comp (cdr comp)))
+ (ede-proj-makefile-insert-object-variables (car comp) name src)
(while link
(ede-linker-only-once (car link)
(ede-proj-makefile-insert-variables (car link)))
(princ "\n")
))
+ (when (arrayp semantic-lex-spp-project-macro-symbol-obarray)
+ (princ "\n Project symbol map:\n")
+ (princ " Your project symbol map is derived from the EDE object:\n ")
+ (princ (object-print ede-object))
+ (princ "\n\n")
+ (let ((macros nil))
+ (mapatoms
+ #'(lambda (symbol)
+ (setq macros (cons symbol macros)))
+ semantic-lex-spp-project-macro-symbol-obarray)
+ (dolist (S macros)
+ (princ " ")
+ (princ (symbol-name S))
+ (princ " = ")
+ (princ (symbol-value S))
+ (princ "\n")
+ )))
+
(princ "\n\n Use: M-x semantic-lex-spp-describe RET\n")
(princ "\n to see the complete macro table.\n")
(semantic-displayor-set-completions
displayor
(or
- (and (not (eq na 'displayend))
- (semantic-collector-current-exact-match collector))
+ ;; For the below - This caused problems for Chong Yidong
+ ;; when experimenting with the completion engine. I don't
+ ;; remember what the problem was though, and I wasn't sure why
+ ;; the below two lines were there since they obviously added
+ ;; some odd behavior. -EML
+ ;; (and (not (eq na 'displayend))
+ ;; (semantic-collector-current-exact-match collector))
(semantic-collector-all-completions collector contents))
contents)
;; Ask the displayor to display them.