diff options
author | Bram Moolenaar <Bram@vim.org> | 2004-06-24 15:53:16 +0000 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2004-06-24 15:53:16 +0000 |
commit | f4b8e57ffd048f9ca46dd7618939ba7a1b2294ec (patch) | |
tree | 08865b59e356d861c0d1321e4adaef8385e53635 /runtime/syntax/logtalk.vim | |
parent | 69a7cb473ceae109b61fae9aa04ee0c29afba5d9 (diff) | |
download | vim-f4b8e57ffd048f9ca46dd7618939ba7a1b2294ec.zip |
updated for version 7.0002
Diffstat (limited to 'runtime/syntax/logtalk.vim')
-rw-r--r-- | runtime/syntax/logtalk.vim | 102 |
1 files changed, 29 insertions, 73 deletions
diff --git a/runtime/syntax/logtalk.vim b/runtime/syntax/logtalk.vim index b8218da3e..3cc368d18 100644 --- a/runtime/syntax/logtalk.vim +++ b/runtime/syntax/logtalk.vim @@ -2,7 +2,7 @@ " " Language: Logtalk " Maintainer: Paulo Moura <pmoura@logtalk.org> -" Last Change: 2004 May 16 +" Last Change: 2004 June 1 " Quit when a syntax file was already loaded: @@ -55,9 +55,7 @@ syn region logtalkOpenEntityDir matchgroup=logtalkOpenEntityDirTag start=":- cat " Logtalk closing entity directives -syn match logtalkCloseEntityDir ":- end_object\." -syn match logtalkCloseEntityDir ":- end_protocol\." -syn match logtalkCloseEntityDir ":- end_category\." +syn match logtalkCloseEntityDir ":- end_\(object\|protocol\|category\)\." " Logtalk entity relations @@ -88,38 +86,24 @@ syn region logtalkDir matchgroup=logtalkDirTag start=":- uses(" matchgroup=log " Logtalk built-in predicates -syn match logtalkBuiltIn "\<current_object\ze(" -syn match logtalkBuiltIn "\<current_protocol\ze(" -syn match logtalkBuiltIn "\<current_category\ze(" +syn match logtalkBuiltIn "\<current_\(object\|protocol\|category\)\ze(" -syn match logtalkBuiltIn "\<create_object\ze(" -syn match logtalkBuiltIn "\<create_protocol\ze(" -syn match logtalkBuiltIn "\<create_category\ze(" +syn match logtalkBuiltIn "\<create_\(object\|protocol\|category\)\ze(" -syn match logtalkBuiltIn "\<object_property\ze(" -syn match logtalkBuiltIn "\<protocol_property\ze(" -syn match logtalkBuiltIn "\<category_property\ze(" +syn match logtalkBuiltIn "\<\(object\|protocol\|category\)_property\ze(" -syn match logtalkBuiltIn "\<abolish_object\ze(" -syn match logtalkBuiltIn "\<abolish_protocol\ze(" -syn match logtalkBuiltIn "\<abolish_category\ze(" +syn match logtalkBuiltIn "\<abolish_\(object\|protocol\|category\)\ze(" -syn match logtalkBuiltIn "\<extends_object\ze(" -syn match logtalkBuiltIn "\<extends_protocol\ze(" -syn match logtalkBuiltIn "\<implements_protocol\ze(" -syn match logtalkBuiltIn "\<instantiates_class\ze(" -syn match logtalkBuiltIn "\<specializes_class\ze(" -syn match logtalkBuiltIn "\<imports_category\ze(" +syn match logtalkBuiltIn "\<extends_\(object\|protocol\)\ze(" +syn match logtalkBuiltIn "\<imp\(orts_category\|lements_protocol\)\ze(" +syn match logtalkBuiltIn "\<\(instantiates\|specializes\)_class\ze(" -syn match logtalkBuiltIn "\<abolish_events\ze(" +syn match logtalkBuiltIn "\<\(abolish\|define\)_events\ze(" syn match logtalkBuiltIn "\<current_event\ze(" -syn match logtalkBuiltIn "\<define_events\ze(" -syn match logtalkBuiltIn "\<current_logtalk_flag\ze(" -syn match logtalkBuiltIn "\<set_logtalk_flag\ze(" +syn match logtalkBuiltIn "\<\(current\|set\)_logtalk_flag\ze(" -syn match logtalkBuiltIn "\<logtalk_compile\ze(" -syn match logtalkBuiltIn "\<logtalk_load\ze(" +syn match logtalkBuiltIn "\<logtalk_\(compile\|load\)\ze(" syn match logtalkBuiltIn "\<forall\ze(" syn match logtalkBuiltIn "\<retractall\ze(" @@ -128,24 +112,20 @@ syn match logtalkBuiltIn "\<retractall\ze(" " Logtalk built-in methods syn match logtalkBuiltInMethod "\<parameter\ze(" -syn match logtalkBuiltInMethod "\<self\ze(" -syn match logtalkBuiltInMethod "\<sender\ze(" +syn match logtalkBuiltInMethod "\<se\(lf\|nder\)\ze(" syn match logtalkBuiltInMethod "\<this\ze(" syn match logtalkBuiltInMethod "\<current_predicate\ze(" syn match logtalkBuiltInMethod "\<predicate_property\ze(" syn match logtalkBuiltInMethod "\<abolish\ze(" -syn match logtalkBuiltInMethod "\<asserta\ze(" -syn match logtalkBuiltInMethod "\<assertz\ze(" +syn match logtalkBuiltInMethod "\<assert\(a\|z\)\ze(" syn match logtalkBuiltInMethod "\<clause\ze(" syn match logtalkBuiltInMethod "\<retract\ze(" syn match logtalkBuiltInMethod "\<retractall\ze(" -syn match logtalkBuiltInMethod "\<bagof\ze(" -syn match logtalkBuiltInMethod "\<findall\ze(" -syn match logtalkBuiltInMethod "\<forall\ze(" -syn match logtalkBuiltInMethod "\<setof\ze(" +syn match logtalkBuiltInMethod "\<\(bag\|set\)of\ze(" +syn match logtalkBuiltInMethod "\<f\(ind\|or\)all\ze(" syn match logtalkBuiltInMethod "\<before\ze(" syn match logtalkBuiltInMethod "\<after\ze(" @@ -163,13 +143,12 @@ syn match logtalkOperator "@" syn match logtalkKeyword "\<true\>" syn match logtalkKeyword "\<fail\>" -syn match logtalkKeyword "\<call\ze(" +syn match logtalkKeyword "\<ca\(ll\|tch\)\ze(" syn match logtalkOperator "!" -syn match logtalkOperator "," +" syn match logtalkOperator "," syn match logtalkOperator ";" syn match logtalkOperator "-->" syn match logtalkOperator "->" -syn match logtalkKeyword "\<catch\ze(" syn match logtalkKeyword "\<throw\ze(" @@ -188,8 +167,7 @@ syn match logtalkKeyword "\<integer\ze(" syn match logtalkKeyword "\<float\ze(" syn match logtalkKeyword "\<atomic\ze(" syn match logtalkKeyword "\<compound\ze(" -syn match logtalkKeyword "\<nonvar\ze(" -syn match logtalkKeyword "\<number\ze(" +syn match logtalkKeyword "\<n\(onvar\|umber\)\ze(" " Term comparison @@ -227,10 +205,8 @@ syn match logtalkOperator ">=" " Stream selection and control -syn match logtalkKeyword "\<current_input\ze(" -syn match logtalkKeyword "\<current_output\ze(" -syn match logtalkKeyword "\<set_input\ze(" -syn match logtalkKeyword "\<set_output\ze(" +syn match logtalkKeyword "\<current_\(input\|output\)\ze(" +syn match logtalkKeyword "\<set_\(input\|output\)\ze(" syn match logtalkKeyword "\<open\ze(" syn match logtalkKeyword "\<close\ze(" syn match logtalkKeyword "\<flush_output\ze(" @@ -241,33 +217,20 @@ syn match logtalkKeyword "\<at_end_of_stream\>" syn match logtalkKeyword "\<set_stream_position\ze(" -" Character input/output +" Character and byte input/output -syn match logtalkKeyword "\<get_char\ze(" -syn match logtalkKeyword "\<get_code\ze(" -syn match logtalkKeyword "\<peek_char\ze(" -syn match logtalkKeyword "\<peek_code\ze(" -syn match logtalkKeyword "\<put_char\ze(" -syn match logtalkKeyword "\<put_code\ze(" +syn match logtalkKeyword "\<\(get\|peek\|put\)_\(char\|code\|byte\)\ze(" syn match logtalkKeyword "\<nl\ze(" syn match logtalkKeyword "\<nl\>" -" Byte input/output - -syn match logtalkKeyword "\<get_byte\ze(" -syn match logtalkKeyword "\<peek_byte\ze(" -syn match logtalkKeyword "\<put_byte\ze(" - - " Term input/output syn match logtalkKeyword "\<read_term\ze(" syn match logtalkKeyword "\<read\ze(" -syn match logtalkKeyword "\<write_term\ze(" syn match logtalkKeyword "\<write\ze(" syn match logtalkKeyword "\<writeq\ze(" -syn match logtalkKeyword "\<write_canonical\ze(" +syn match logtalkKeyword "\<write_\(canonical\|term\)\ze(" syn match logtalkKeyword "\<op\ze(" syn match logtalkKeyword "\<current_op\ze(" syn match logtalkKeyword "\<char_conversion\ze(" @@ -283,20 +246,15 @@ syn match logtalkKeyword "\<repeat\>" " Atomic term processing -syn match logtalkKeyword "\<atom_length\ze(" -syn match logtalkKeyword "\<atom_concat\ze(" +syn match logtalkKeyword "\<atom_\(length\|concat\|chars\|codes\)\ze(" syn match logtalkKeyword "\<sub_atom\ze(" -syn match logtalkKeyword "\<atom_chars\ze(" -syn match logtalkKeyword "\<atom_codes\ze(" syn match logtalkKeyword "\<char_code\ze(" -syn match logtalkKeyword "\<number_chars\ze(" -syn match logtalkKeyword "\<number_codes\ze(" +syn match logtalkKeyword "\<number_\(chars\|codes\)\ze(" " Implementation defined hooks functions -syn match logtalkKeyword "\<set_prolog_flag\ze(" -syn match logtalkKeyword "\<current_prolog_flag\ze(" +syn match logtalkKeyword "\<\(current\|set\)_prolog_flag\ze(" syn match logtalkKeyword "\<halt\ze(" syn match logtalkKeyword "\<halt\>" @@ -314,8 +272,7 @@ syn match logtalkKeyword "\<mod\ze(" syn match logtalkKeyword "\<mod\>" syn match logtalkKeyword "\<abs\ze(" syn match logtalkKeyword "\<sign\ze(" -syn match logtalkKeyword "\<float_integer_part\ze(" -syn match logtalkKeyword "\<float_fractional_part\ze(" +syn match logtalkKeyword "\<float_\(integer\|fractional\)_part\ze(" syn match logtalkKeyword "\<float\ze(" syn match logtalkKeyword "\<floor\ze(" syn match logtalkKeyword "\<truncate\ze(" @@ -326,12 +283,11 @@ syn match logtalkKeyword "\<ceiling\ze(" " Other arithemtic functors syn match logtalkOperator "\*\*" -syn match logtalkKeyword "\<sin\ze(" +syn match logtalkKeyword "\<s\(in\|qrt\)\ze(" syn match logtalkKeyword "\<cos\ze(" syn match logtalkKeyword "\<atan\ze(" syn match logtalkKeyword "\<exp\ze(" syn match logtalkKeyword "\<log\ze(" -syn match logtalkKeyword "\<sqrt\ze(" " Bitwise functors |