@@ -7,29 +7,35 @@ if exists("b:current_syntax")
77 finish
88endif
99
10- syntax keyword recKeyword % allowed % auto % confidential % constraint % doc % key
11- syntax keyword recKeyword % mandatory % prohibit % rec % size % sort % unique
10+ syntax keyword recKeyword % allowed % auto % confidential % doc % key
11+ syntax keyword recKeyword % mandatory % prohibit % rec % sort % unique
1212syntax keyword recKeyword % unique
1313
1414syntax match recComment " \v ^#.*$"
1515syntax match recField " \v ^[a-zA-Z0-9_]*\: "
16+ syntax match recComparisonOperator " \v\> ?\< ?\! ?\= ?" contained
1617
1718syntax keyword recType int bool range real size line regexp date contained containedin =recTypeAssociation,recTypeDeclaration
1819syntax keyword recType enum field email uuid rec contained containedin =recTypeAssociation,recTypeDeclaration
1920syntax region recTypeComment start =" \v\( " end =" \v\) " contained containedin =recTypeAssociation,recTypeDeclaration
2021syntax match recTypeAssociation " \v ^[%]type\: .*" hs =s ,he =s + 5 contains =recType
2122syntax match recTypeDeclaration " \v ^[%]typedef\: .*" hs =s ,he =s + 8 contains =recType
2223syntax keyword recTypeLimit MIN MAX contained containedin =recTypeAssociation,recTypeDeclaration
24+ syntax match recConstraintDeclaration " \v ^[%]constraint\: .*" hs =s ,he =s + 11 contains =recComparisonOperator
25+ syntax match recSizeDeclaration " \v ^[%]size\: .*" hs =s ,he =s + 5 contains =recComparisonOperator
2326
2427syntax match recNumber " \v\- ?\d +"
2528syntax match recNumber " \v\- ?\d +\.\d +"
2629syntax match recNumber " \v\- ?0[0-7]+"
2730syntax match recNumber " \v\- ?0[xX][0-9a-fA-F]+"
2831
2932highlight default link recComment Comment
33+ highlight default link recComparisonOperator Operator
34+ highlight default link recConstraintDeclaration Keyword
3035highlight default link recField Identifier
3136highlight default link recKeyword Keyword
3237highlight default link recNumber Number
38+ highlight default link recSizeDeclaration Keyword
3339highlight default link recType Type
3440highlight default link recTypeAssociation Keyword
3541highlight default link recTypeComment Comment
0 commit comments