From 7e24f6b7ce82f3ad1f4429de9077c0b0aa34a893 Mon Sep 17 00:00:00 2001 From: Alex Brick Date: Wed, 24 Oct 2007 00:00:00 +0000 Subject: Version 1.0.1 A minor fix to enable 6.x compatibility (noticed and patched by Jarmo Jaakkola), and a fix to hexadecimal numbers. --- syntax/mips.vim | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'syntax') diff --git a/syntax/mips.vim b/syntax/mips.vim index e8d81b5..325f1dd 100644 --- a/syntax/mips.vim +++ b/syntax/mips.vim @@ -14,7 +14,7 @@ syntax case match syntax match mipsComment /#.*/ syntax match mipsNumber /\<[-]\?\d\+\>/ " Decimal numbers -syntax match mipsNumber /\<-\?0\(x\|X\)\d\+\>/ " Hex numbers +syntax match mipsNumber /\<-\?0\(x\|X\)[0-9a-fA-F]\+\>/ " Hex numbers syntax region mipsString start=/"/ skip=/\\"/ end=/"/ syntax match mipsLabelColon /:/ contained syntax match mipsLabel /\w\+:/ contains=mipsLabelColon @@ -52,12 +52,14 @@ syntax match mipsRegister "\$sp" syntax match mipsRegister "\$fp" syntax match mipsRegister "\$ra" -for i in range(0, 31) +let i = 0 +while i < 32 " This is for the regular registers execute 'syntax match mipsRegister "\$' . i . '\(\d\+\)\@!"' " And this is for the FP registers execute 'syntax match mipsRegister "\$f' . i . '\(\d\+\)\@!"' -endfor + let i = i + 1 +endwhile " Directives syntax match mipsDirective "\.2byte" -- cgit v1.2.3