In matlab-mode, setup `forward-sexp-function' so any random tools using it (like blink-paren-mode) will

get the benefits of our fancy matlab specific sexp navigation.
This commit is contained in:
Eric Ludlam 2019-10-06 21:40:06 -04:00
parent a58df74bf1
commit b3c06728ef

View file

@ -62,7 +62,7 @@
(defalias 'matlab-make-overlay 'make-extent)
(defalias 'matlab-overlay-put 'set-extent-property)
(defalias 'matlab-overlay-get 'extent-property)
(defalias 'matlab-delete-overlay 'delete-extent)
(defalias 'matlab-delete-overlay 'delete-extent)p
(defalias 'matlab-overlay-start 'extent-start-position)
(defalias 'matlab-overlay-end 'extent-end-position)
(defalias 'matlab-previous-overlay-change 'previous-extent-change)
@ -1351,6 +1351,10 @@ All Key Bindings:
(matlab-enable-block-highlighting 1)
(if window-system (matlab-frame-init)))
;; built-in sexp navigation
(make-local-variable 'forward-sexp-function)
(setq forward-sexp-function #'matlab-move-simple-sexp-internal)
;; If first function is terminated with an end statement, then functions have
;; ends.
(if (matlab-do-functions-have-end-p)