Remove semantic-make-local-hook call from CEDET

* lisp/cedet/semantic/wisent/grammar.el
(wisent-grammar-setupcode-builder):
* lisp/cedet/semantic/util-modes.el (semantic-highlight-edits-mode)
(semantic-show-unmatched-syntax-mode)
(semantic-show-parser-state-mode):
* lisp/cedet/semantic/mru-bookmark.el (semantic-mru-bookmark-mode):
* lisp/cedet/semantic/imenu.el (semantic-create-imenu-index):
* lisp/cedet/semantic/grammar.el (semantic-grammar-mode):
* lisp/cedet/semantic/grammar-wy.el
(semantic-grammar-wy--install-parser):
* lisp/cedet/semantic/decorate/mode.el
(semantic-decorate-add-pending-decoration)
(semantic-decoration-mode):
* lisp/cedet/semantic.el (semantic--set-buffer-cache): Remove all
calls to the function.

* lisp/cedet/semantic/fw.el (semantic-make-local-hook): Made
obsolete alias for #'ignore by removing XEmacs compat code.
This commit is contained in:
Lars Ingebrigtsen 2019-10-04 15:29:30 +02:00
parent 33702988d9
commit 5f06b9c478
9 changed files with 1 additions and 25 deletions

View file

@ -535,7 +535,6 @@ is requested."
(set (make-local-variable 'semantic-bovinate-nonterminal-check-obarray)
nil)
(semantic-parse-tree-set-up-to-date)
(semantic-make-local-hook 'after-change-functions)
(add-hook 'after-change-functions 'semantic-change-function nil t)
(run-hook-with-args 'semantic-after-toplevel-cache-change-hook
semantic--buffer-cache)

View file

@ -213,7 +213,6 @@ Applies only to the current BUFFER.
The setting of FCN will be removed after it is run."
(save-excursion
(when buffer (set-buffer buffer))
(semantic-make-local-hook 'semantic-decorate-flush-pending-decorations)
(add-hook 'semantic-decorate-pending-decoration-hook fcn nil t)))
(defun semantic-decorate-flush-pending-decorations (&optional buffer)
@ -267,10 +266,8 @@ non-nil if the minor mode is enabled."
(error "Buffer %s was not set up for parsing"
(buffer-name)))
;; Add hooks
(semantic-make-local-hook 'semantic-after-partial-cache-change-hook)
(add-hook 'semantic-after-partial-cache-change-hook
'semantic-decorate-tags-after-partial-reparse nil t)
(semantic-make-local-hook 'semantic-after-toplevel-cache-change-hook)
(add-hook 'semantic-after-toplevel-cache-change-hook
'semantic-decorate-tags-after-full-reparse nil t)
;; Add decorations to available tags. The above hooks ensure

View file

@ -62,9 +62,7 @@
"Extract the window from EVENT."
(car (car (cdr event))))
(defalias 'semantic-make-local-hook
(if (featurep 'emacs)
#'identity #'make-local-hook))
(define-obsolete-function-alias 'semantic-make-local-hook #'identity "27.1")
(defalias 'semantic-mode-line-update #'force-mode-line-update)

View file

@ -428,7 +428,6 @@
semantic-flex-keywords-obarray semantic-grammar-wy--keyword-table
semantic-lex-types-obarray semantic-grammar-wy--token-table)
;; Collect unmatched syntax lexical tokens
(semantic-make-local-hook 'wisent-discarding-token-functions)
(add-hook 'wisent-discarding-token-functions
'wisent-collect-unmatched-syntax nil t))

View file

@ -1348,11 +1348,9 @@ the change bounds to encompass the whole nonterminal tag."
'(nonterminal))
;; Before each change, clear the cached regexp used to highlight
;; macros local in this grammar.
(semantic-make-local-hook 'before-change-functions)
(add-hook 'before-change-functions
'semantic--grammar-clear-macros-regexp-2 nil t)
;; Handle safe re-parse of grammar rules.
(semantic-make-local-hook 'semantic-edits-new-change-functions)
(add-hook 'semantic-edits-new-change-functions
'semantic-grammar-edits-new-change-hook-fcn
nil t))

View file

@ -240,10 +240,8 @@ Optional argument STREAM is an optional stream of tags used to create menus."
(or stream (semantic-fetch-tags-fast)))
(semantic-create-imenu-index-1
(or stream (semantic-fetch-tags-fast)) nil))
(semantic-make-local-hook 'semantic-after-toplevel-cache-change-hook)
(add-hook 'semantic-after-toplevel-cache-change-hook
'semantic-imenu-flush-fcn nil t)
(semantic-make-local-hook 'semantic-after-partial-cache-change-hook)
(add-hook 'semantic-after-partial-cache-change-hook
'semantic-imenu-flush-fcn nil t)))

View file

@ -288,7 +288,6 @@ non-nil if the minor mode is enabled."
(setq semantic-mru-bookmark-mode nil)
(error "Buffer %s was not set up for parsing"
(buffer-name)))
(semantic-make-local-hook 'semantic-edits-new-change-functions)
(add-hook 'semantic-edits-new-change-functions
'semantic-mru-bookmark-change-hook-fcn nil t)
(add-hook 'semantic-edits-move-change-hooks

View file

@ -220,7 +220,6 @@ non-nil if the minor mode is enabled."
(setq semantic-highlight-edits-mode nil)
(error "Buffer %s was not set up for parsing"
(buffer-name)))
(semantic-make-local-hook 'semantic-edits-new-change-functions)
(add-hook 'semantic-edits-new-change-functions
'semantic-highlight-edits-new-change-hook-fcn nil t))
;; Remove hooks
@ -372,10 +371,8 @@ non-nil if the minor mode is enabled.
(error "Buffer %s was not set up for parsing"
(buffer-name)))
;; Add hooks
(semantic-make-local-hook 'semantic-unmatched-syntax-hook)
(add-hook 'semantic-unmatched-syntax-hook
'semantic-show-unmatched-syntax nil t)
(semantic-make-local-hook 'semantic-pre-clean-token-hooks)
(add-hook 'semantic-pre-clean-token-hooks
'semantic-clean-token-of-unmatched-syntax nil t)
;; Show unmatched syntax elements
@ -456,31 +453,23 @@ non-nil if the minor mode is enabled."
(append mode-line-modified
'(semantic-show-parser-state-string))))
;; Add hooks
(semantic-make-local-hook 'semantic-edits-new-change-functions)
(add-hook 'semantic-edits-new-change-functions
'semantic-show-parser-state-marker nil t)
(semantic-make-local-hook 'semantic-edits-incremental-reparse-failed-hook)
(add-hook 'semantic-edits-incremental-reparse-failed-hook
'semantic-show-parser-state-marker nil t)
(semantic-make-local-hook 'semantic-after-partial-cache-change-hook)
(add-hook 'semantic-after-partial-cache-change-hook
'semantic-show-parser-state-marker nil t)
(semantic-make-local-hook 'semantic-after-toplevel-cache-change-hook)
(add-hook 'semantic-after-toplevel-cache-change-hook
'semantic-show-parser-state-marker nil t)
(semantic-show-parser-state-marker)
(semantic-make-local-hook 'semantic-before-auto-parse-hooks)
(add-hook 'semantic-before-auto-parse-hooks
'semantic-show-parser-state-auto-marker nil t)
(semantic-make-local-hook 'semantic-after-auto-parse-hooks)
(add-hook 'semantic-after-auto-parse-hooks
'semantic-show-parser-state-marker nil t)
(semantic-make-local-hook 'semantic-before-idle-scheduler-reparse-hook)
(add-hook 'semantic-before-idle-scheduler-reparse-hook
'semantic-show-parser-state-auto-marker nil t)
(semantic-make-local-hook 'semantic-after-idle-scheduler-reparse-hook)
(add-hook 'semantic-after-idle-scheduler-reparse-hook
'semantic-show-parser-state-marker nil t))
;; Remove parts of mode line

View file

@ -304,7 +304,6 @@ Return the expanded expression."
semantic-flex-keywords-obarray %s\n\
semantic-lex-types-obarray %s)\n\
;; Collect unmatched syntax lexical tokens\n\
(semantic-make-local-hook 'wisent-discarding-token-functions)\n\
(add-hook 'wisent-discarding-token-functions\n\
'wisent-collect-unmatched-syntax nil t)"
(semantic-grammar-parsetable)