Hello Everyone.
I'm working on a bundle for Assembly for the 8051/52 family. I wanted to add some simple indentation, example:
RSEG TAGS TAGS1: MOV A,@R1 ; after this line indent all the following MOV B,@R0 RET ; after this line decrease indent JMP $
I tried this code for the indentation rule: { decreaseIndentPattern = 'RET|END'; increaseIndentPattern = '*:'; indentNextLinePattern = '*:'; }
But it doesn't do the job.. Any ideas what I'm doing wrong?
Thanks in advance!
On 10 May 2011, at 03:17, chuti89 wrote:
I tried this code for the indentation rule: { decreaseIndentPattern = 'RET|END'; increaseIndentPattern = '*:'; indentNextLinePattern = '*:'; }
But it doesn't do the job.. Any ideas what I'm doing wrong?
Your patterns are not regular expressions.
To match ‘anything followed by colon’ you’d do ‘.*:’ not ‘*:’.
You probably should leave out indentNextLinePattern. This is for cases where the current line should indent the next line, but not those following it, e.g. a “for” not followed by braces in C-like languages.