Add ~44 edebug specs to CC Mode.
* lisp/progmodes/cc-cmds.el, lisp/progmodes/cc-defs.el lisp/progmodes/cc-engine.el, lisp/progmodes/cc-fonts.el lisp/progmodes/cc-langs.el: Add lots of edebug specs. * lisp/progmodes/cc-engine.el (c-state-maybe-marker): Tidy up so as to evaluate an argument only once at runtime.
This commit is contained in:
parent
8c68e4afa8
commit
aba7910e36
5 changed files with 52 additions and 4 deletions
|
@ -1640,6 +1640,8 @@ No indentation or other \"electric\" behavior is performed."
|
|||
paren-state orig-point-min orig-point-max))
|
||||
(setq where 'in-block))))
|
||||
|
||||
(def-edebug-spec c-while-widening-to-decl-block t)
|
||||
|
||||
(defun c-beginning-of-defun (&optional arg)
|
||||
"Move backward to the beginning of a defun.
|
||||
Every top level declaration that contains a brace paren block is
|
||||
|
|
|
@ -1316,20 +1316,36 @@ with value CHAR in the region [FROM to)."
|
|||
;(eval-after-load "edebug" ; 2006-07-09: def-edebug-spec is now in subr.el.
|
||||
; '(progn
|
||||
(def-edebug-spec cc-eval-when-compile (&rest def-form))
|
||||
(def-edebug-spec c--mapcan t)
|
||||
(def-edebug-spec c--set-difference (form form &rest [symbolp form]))
|
||||
(def-edebug-spec c--intersection (form form &rest [symbolp form]))
|
||||
(def-edebug-spec c--delete-duplicates (form &rest [symbolp form]))
|
||||
(def-edebug-spec c-point t)
|
||||
(def-edebug-spec c-next-single-property-change t)
|
||||
(def-edebug-spec c-delete-and-extract-region t)
|
||||
(def-edebug-spec c-set-region-active t)
|
||||
(def-edebug-spec c-set-keymap-parent t)
|
||||
(def-edebug-spec c-safe t)
|
||||
(def-edebug-spec c-int-to-char t)
|
||||
(def-edebug-spec c-characterp t)
|
||||
(def-edebug-spec c-save-buffer-state let*)
|
||||
(def-edebug-spec c-tentative-buffer-changes t)
|
||||
(def-edebug-spec c-forward-syntactic-ws t)
|
||||
(def-edebug-spec c-backward-syntactic-ws t)
|
||||
(def-edebug-spec c-forward-sexp t)
|
||||
(def-edebug-spec c-backward-sexp t)
|
||||
(def-edebug-spec c-safe-scan-lists t)
|
||||
(def-edebug-spec c-go-list-forward t)
|
||||
(def-edebug-spec c-go-list-backward t)
|
||||
(def-edebug-spec c-up-list-forward t)
|
||||
(def-edebug-spec c-up-list-backward t)
|
||||
(def-edebug-spec c-down-list-forward t)
|
||||
(def-edebug-spec c-down-list-backward t)
|
||||
(def-edebug-spec c-go-up-list-forward t)
|
||||
(def-edebug-spec c-go-up-list-backward t)
|
||||
(def-edebug-spec c-go-down-list-forward t)
|
||||
(def-edebug-spec c-go-down-list-backward t)
|
||||
(def-edebug-spec c-at-vsemi-p t)
|
||||
(def-edebug-spec c-add-syntax t)
|
||||
(def-edebug-spec c-add-class-syntax t)
|
||||
(def-edebug-spec c-benign-error t)
|
||||
|
@ -1337,15 +1353,28 @@ with value CHAR in the region [FROM to)."
|
|||
(def-edebug-spec c-skip-ws-forward t)
|
||||
(def-edebug-spec c-skip-ws-backward t)
|
||||
(def-edebug-spec c-major-mode-is t)
|
||||
(def-edebug-spec c-search-forward-char-property t)
|
||||
(def-edebug-spec c-search-backward-char-property t)
|
||||
(def-edebug-spec c-put-char-property t)
|
||||
(def-edebug-spec c-get-char-property t)
|
||||
(def-edebug-spec c-clear-char-property t)
|
||||
(def-edebug-spec c-clear-char-property-with-value t)
|
||||
(def-edebug-spec c-clear-char-property-with-value-on-char t)
|
||||
(def-edebug-spec c-put-char-properties-on-char t)
|
||||
(def-edebug-spec c-clear-char-properties t)
|
||||
(def-edebug-spec c-put-overlay t)
|
||||
(def-edebug-spec c-delete-overlay t)
|
||||
(def-edebug-spec c-self-bind-state-cache t);))
|
||||
(def-edebug-spec c-mark-<-as-paren t)
|
||||
(def-edebug-spec c-mark->-as-paren t)
|
||||
(def-edebug-spec c-unmark-<->-as-paren t)
|
||||
(def-edebug-spec c-with-<->-as-parens-suppressed (body))
|
||||
(def-edebug-spec c-self-bind-state-cache (body))
|
||||
(def-edebug-spec c-sc-scan-lists-no-category+1+1 t)
|
||||
(def-edebug-spec c-sc-scan-lists-no-category+1-1 t)
|
||||
(def-edebug-spec c-sc-scan-lists-no-category-1+1 t)
|
||||
(def-edebug-spec c-sc-scan-lists-no-category-1-1 t)
|
||||
(def-edebug-spec c-sc-scan-lists t)
|
||||
(def-edebug-spec c-sc-parse-partial-sexp t);))
|
||||
|
||||
|
||||
;;; Functions.
|
||||
|
|
|
@ -3879,9 +3879,10 @@ comment at the start of cc-engine.el for more info."
|
|||
(defmacro c-state-maybe-marker (place marker)
|
||||
;; If PLACE is non-nil, return a marker marking it, otherwise nil.
|
||||
;; We (re)use MARKER.
|
||||
`(and ,place
|
||||
(or ,marker (setq ,marker (make-marker)))
|
||||
(set-marker ,marker ,place)))
|
||||
`(let ((-place- ,place))
|
||||
(and -place-
|
||||
(or ,marker (setq ,marker (make-marker)))
|
||||
(set-marker ,marker -place-))))
|
||||
|
||||
(defun c-parse-state ()
|
||||
;; This is a wrapper over `c-parse-state-1'. See that function for a
|
||||
|
@ -13253,6 +13254,18 @@ Cannot combine absolute offsets %S and %S in `add' method"
|
|||
(current-column)))
|
||||
indent)))
|
||||
|
||||
|
||||
(def-edebug-spec c-bos-pop-state t)
|
||||
(def-edebug-spec c-bos-save-error-info t)
|
||||
(def-edebug-spec c-state-cache-top-lparen t)
|
||||
(def-edebug-spec c-state-cache-top-paren t)
|
||||
(def-edebug-spec c-state-cache-after-top-paren t)
|
||||
(def-edebug-spec c-state-maybe-marker (form symbolp))
|
||||
(def-edebug-spec c-record-type-id t)
|
||||
(def-edebug-spec c-record-ref-id t)
|
||||
(def-edebug-spec c-forward-keyword-prefixed-id t)
|
||||
(def-edebug-spec c-forward-id-comma-list t)
|
||||
(def-edebug-spec c-pull-open-brace (symbolp))
|
||||
|
||||
(cc-provide 'cc-engine)
|
||||
|
||||
|
|
|
@ -488,6 +488,9 @@
|
|||
|
||||
; (eval-after-load "edebug" ; 2006-07-09: def-edebug-spec is now in subr.el.
|
||||
; '(progn
|
||||
(def-edebug-spec c-put-font-lock-face t)
|
||||
(def-edebug-spec c-remove-font-lock-face t)
|
||||
(def-edebug-spec c-put-font-lock-string-face t)
|
||||
(def-edebug-spec c-fontify-types-and-refs let*)
|
||||
(def-edebug-spec c-make-syntactic-matcher t)
|
||||
;; If there are literal quoted or backquoted highlight specs in
|
||||
|
|
|
@ -205,6 +205,7 @@ the evaluated constant value at compile time."
|
|||
; '
|
||||
(def-edebug-spec c-lang-defvar
|
||||
(&define name def-form &optional &or ("quote" symbolp) stringp))
|
||||
(def-edebug-spec c-lang-setvar (&define name def-form))
|
||||
|
||||
;; Suppress "might not be defined at runtime" warning.
|
||||
;; This file is only used when compiling other cc files.
|
||||
|
|
Loading…
Add table
Reference in a new issue