From help-request at octave dot org Tue Jan 4 22:59:15 2005 Subject: "end" keyword problem in Emacs Octave mode From: Jonathan Stickel To: help at octave dot org Date: Tue, 04 Jan 2005 21:01:15 -0800 For some time now I've been bothered by a problem in the Emacs Octave mode, specifically that the keyword "end" is not treated correctly when it is used to denote the last index of an array dimension. For example, consider the code: a = 1:5; for i = 1:length(a) a(i:end) endfor In emacs octave mode, pressing "tab" or "line-feed" on the endfor line results in an "unbalanced block" error. Emacs thinks that the "end" inside the array designation balances the "for" statement. Have other people encountered this problem and found a workaround? Clearly the correct fix would be to patch octave-mod.el to account for the dual use of "end", but I suspect this is not easy to do. I don't know enough elisp to fix it myself. Thanks, Jonathan P.S. Who maintains octave-mod.el? I see that it is supplied by my octave package in Linux. Should emacs octave mode problems be reported to bugs at octave dot org? ------------------------------------------------------------- Octave is freely available under the terms of the GNU GPL. Octave's home on the web: http://www.octave.org How to fund new projects: http://www.octave.org/funding.html Subscription information: http://www.octave.org/archive.html -------------------------------------------------------------