Function: semantic-prototype-file
semantic-prototype-file is a byte-compiled function defined in
tag-file.el.gz.
Signature
(semantic-prototype-file BUFFER)
Documentation
Return a file in which prototypes belonging to BUFFER should be placed.
Default behavior (if not overridden) looks for a token specifying the prototype file, or the existence of an EDE variable indicating which file prototypes belong in.
Source Code
;; Defined in /usr/src/emacs/lisp/cedet/semantic/tag-file.el.gz
;;; PROTOTYPE FILE
;;
;; In C, a function in the .c file often has a representation in a
;; corresponding .h file. This routine attempts to find the
;; prototype file a given source file would be associated with.
;; This can be used by prototype manager programs.
(define-overloadable-function semantic-prototype-file (buffer)
"Return a file in which prototypes belonging to BUFFER should be placed.
Default behavior (if not overridden) looks for a token specifying the
prototype file, or the existence of an EDE variable indicating which
file prototypes belong in."
(:override
;; Perform some default behaviors
(if (and (fboundp 'ede-header-file) ede-minor-mode)
(with-current-buffer buffer
(ede-header-file))
;; No EDE options for a quick answer. Search.
(with-current-buffer buffer
(if (re-search-forward "::Header:: \\([a-zA-Z0-9.]+\\)" nil t)
(match-string 1))))))