Subject: Re: bug#14332: 24.3; Octave indentation bug

From: Stefan Monnier <[email-masked]>
Date: Sun, 05 May 2013 21:04:14 -0400

>> You'll probably need to add some syntax-propertize case.
>> What does "(1 \(2-3))" mean in Octave?  Where else can \ appear in
>> Octave code?

> A \ 1 ≡ inv(A) # one over matrix A, with some optimisation

> if A is a scalar, A \ 1 = 1 / A.

> so \ is an operator.

Then your best bet is probably to put in the mode's syntax-table the
syntax corresponding to the most common use of \ (either as an escape
char in strings or as an operator), and then use syntax-propertize to
put the other syntax on the other case (where you can check (nth
3 (syntax-ppss (math-beginning 0))) to see if you're within a string).

        Stefan