[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

octave-mode/SMIE question

From: Eduard Wiebe
Subject: octave-mode/SMIE question
Date: Wed, 04 Jun 2014 23:52:53 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)


i have a question about `octave-mode' and/or SMIE.

Consider the following snippet:

(define-derived-mode matlab-mode octave-mode "MATLAB"
  "My poor man's MATLAB mode based on `octave-mode'.
  (setq-local octave-end-keywords '("end")) ;; Without an effect
  (setq-local octave-comment-char ?\%)
  (setq-local octave-comment-start "%")
  (setq-local octave-block-offset 4)
  (setq-local octave-block-comment-start "%% "))

If matlab-mode is loaded and i use `smie-close-block' (C-c /), then
each block is closed with Octave-specific close token ('if' is closed
with 'endif', 'while' with 'endwhile' and so on).

But MATLAB-grammar knows only `end' as a block close token.

How i can accomplish the intended behaviour of `smie-close-block' for
my matlab-mode? Or is an advice my last chace?

Eduard Wiebe

reply via email to

[Prev in Thread] Current Thread [Next in Thread]