Constant tree_sitter_tlaplus::HIGHLIGHTS_QUERY

source ·
pub const HIGHLIGHTS_QUERY: &str = "; ; Intended for consumption by GitHub and the tree-sitter highlight command\n; ; Default capture names found here:\n; ; https://github.com/tree-sitter/tree-sitter/blob/f5d1c0b8609f8697861eab352ead44916c068c74/cli/src/highlight.rs#L150-L171\n; ; In this file, captures defined earlier take precedence over captures defined later.\n\n; TLA\u{207a} Keywords\n[\n  \"ACTION\"\n  \"ASSUME\"\n  \"ASSUMPTION\"\n  \"AXIOM\"\n  \"BY\"\n  \"CASE\"\n  \"CHOOSE\"\n  \"CONSTANT\"\n  \"CONSTANTS\"\n  \"COROLLARY\"\n  \"DEF\"\n  \"DEFINE\"\n  \"DEFS\"\n  \"DOMAIN\"\n  \"ELSE\"\n  \"ENABLED\"\n  \"EXCEPT\"\n  \"EXTENDS\"\n  \"HAVE\"\n  \"HIDE\"\n  \"IF\"\n  \"IN\"\n  \"INSTANCE\"\n  \"LAMBDA\"\n  \"LEMMA\"\n  \"LET\"\n  \"LOCAL\"\n  \"MODULE\"\n  \"NEW\"\n  \"OBVIOUS\"\n  \"OMITTED\"\n  \"ONLY\"\n  \"OTHER\"\n  \"PICK\"\n  \"PROOF\"\n  \"PROPOSITION\"\n  \"PROVE\"\n  \"QED\"\n  \"RECURSIVE\"\n  \"SF_\"\n  \"STATE\"\n  \"SUBSET\"\n  \"SUFFICES\"\n  \"TAKE\"\n  \"TEMPORAL\"\n  \"THEN\"\n  \"THEOREM\"\n  \"UNCHANGED\"\n  \"UNION\"\n  \"USE\"\n  \"VARIABLE\"\n  \"VARIABLES\"\n  \"WF_\"\n  \"WITH\"\n  \"WITNESS\"\n  (address)\n  (all_map_to)\n  (assign)\n  (case_arrow)\n  (case_box)\n  (def_eq)\n  (exists)\n  (forall)\n  (gets)\n  (label_as)\n  (maps_to)\n  (set_in)\n  (temporal_exists)\n  (temporal_forall)\n] @keyword\n\n;  PlusCal keywords\n[\n  \"algorithm\"\n  \"assert\"\n  \"await\"\n  \"begin\"\n  \"call\"\n  \"define\"\n  \"either\"\n  \"else\" \n  \"elsif\"\n  \"end\"\n  \"fair\"\n  \"goto\"\n  \"if\" \n  \"macro\"\n  \"or\"\n  \"print\"\n  \"procedure\"\n  \"process\"\n  \"return\"\n  \"skip\"\n  \"variable\"\n  \"variables\"\n  \"when\"\n  \"with\"\n  \"then\" \n  (pcal_algorithm_start)\n  (pcal_end_either)\n  (pcal_end_if)\n  (pcal_process (\"=\"))\n  (pcal_with (\"=\"))\n] @keyword\n\n; Literals\n(binary_number (format) @keyword)\n(binary_number (value) @number)\n(boolean) @number\n(boolean_set) @type\n(hex_number (format) @keyword)\n(hex_number (value) @number)\n(int_number_set) @type\n(nat_number) @number\n(nat_number_set) @type\n(octal_number (format) @keyword)\n(octal_number (value) @number)\n(real_number) @number\n(real_number_set) @type\n(string) @string\n(escape_char) @string.special\n(string_set) @type\n\n; Namespaces and includes\n(extends (identifier_ref) @module)\n(instance (identifier_ref) @module)\n(module name: (_) @module)\n(pcal_algorithm name: (identifier) @module)\n\n; Constants and variables\n(constant_declaration (identifier) @constant)\n(constant_declaration (operator_declaration name: (_) @constant))\n(pcal_var_decl (identifier) @variable.builtin)\n(pcal_with (identifier) @variable.parameter)\n((\".\") . (identifier) @attribute)\n(record_literal (identifier) @attribute)\n(set_of_records (identifier) @attribute)\n(variable_declaration (identifier) @variable.builtin)\n\n; Parameters\n(choose (identifier) @variable.parameter)\n(choose (tuple_of_identifiers (identifier) @variable.parameter))\n(lambda (identifier) @variable.parameter)\n(module_definition (operator_declaration name: (_) @variable.parameter))\n(module_definition parameter: (identifier) @variable.parameter)\n(operator_definition (operator_declaration name: (_) @variable.parameter))\n(operator_definition parameter: (identifier) @variable.parameter)\n(pcal_macro_decl parameter: (identifier) @variable.parameter)\n(pcal_proc_var_decl (identifier) @variable.parameter)\n(quantifier_bound (identifier) @variable.parameter)\n(quantifier_bound (tuple_of_identifiers (identifier) @variable.parameter))\n(unbounded_quantification (identifier) @variable.parameter)\n\n; Operators, functions, and macros\n(function_definition name: (identifier) @function)\n(module_definition name: (_) @module)\n(operator_definition name: (_) @operator)\n(pcal_macro_decl name: (identifier) @function)\n(pcal_macro_call name: (identifier) @function)\n(pcal_proc_decl name: (identifier) @function)\n(pcal_process name: (identifier) @function)\n(recursive_declaration (identifier) @operator)\n(recursive_declaration (operator_declaration name: (_) @operator))\n\n; Delimiters\n[\n  (langle_bracket)\n  (rangle_bracket)\n  (rangle_bracket_sub)\n  \"{\"\n  \"}\"\n  \"[\"\n  \"]\"\n  \"]_\"\n  \"(\"\n  \")\"\n] @punctuation.bracket\n[\n  \",\"\n  \":\"\n  \".\"\n  \"!\"\n  \";\"\n  (bullet_conj)\n  (bullet_disj)\n  (prev_func_val)\n  (placeholder)\n] @punctuation.delimiter\n\n; Proofs\n(assume_prove (new (identifier) @variable.parameter))\n(assume_prove (new (operator_declaration name: (_) @variable.parameter)))\n(assumption name: (identifier) @constant)\n(pick_proof_step (identifier) @variable.parameter)\n(proof_step_id \"<\" @punctuation.bracket)\n(proof_step_id (level) @tag)\n(proof_step_id (name) @tag)\n(proof_step_id \">\" @punctuation.bracket)\n(proof_step_ref \"<\" @punctuation.bracket)\n(proof_step_ref (level) @tag)\n(proof_step_ref (name) @tag)\n(proof_step_ref \">\" @punctuation.bracket)\n(take_proof_step (identifier) @variable.parameter)\n(theorem name: (identifier) @constant)\n\n; Comments and tags\n(block_comment \"(*\" @comment)\n(block_comment \"*)\" @comment)\n(block_comment_text) @comment\n(comment) @comment\n(single_line) @comment\n(_ label: (identifier) @tag)\n(label name: (_) @tag)\n(pcal_goto statement: (identifier) @tag)\n\n; Put these last so they are overridden by everything else\n(bound_infix_op symbol: (_) @function.builtin)\n(bound_nonfix_op symbol: (_) @function.builtin)\n(bound_postfix_op symbol: (_) @function.builtin)\n(bound_prefix_op symbol: (_) @function.builtin)\n((prefix_op_symbol) @function.builtin)\n((infix_op_symbol) @function.builtin)\n((postfix_op_symbol) @function.builtin)\n\n; Reference highlighting\n(identifier_ref) @variable.reference\n((prefix_op_symbol) @variable.reference)\n(bound_prefix_op symbol: (_) @variable.reference)\n((infix_op_symbol) @variable.reference)\n(bound_infix_op symbol: (_) @variable.reference)\n((postfix_op_symbol) @variable.reference)\n(bound_postfix_op symbol: (_) @variable.reference)\n(bound_nonfix_op symbol: (_) @variable.reference)\n";