File: julia.yaml

package info (click to toggle)
micro 2.0.15-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 3,128 kB
  • sloc: sh: 265; makefile: 77; xml: 53
file content (57 lines) | stat: -rw-r--r-- 1,767 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
filetype: julia

detect:
    filename: "\\.jl$"
    header: "^#!.*/(env +)?julia( |$)"

rules:

    # built-in objects
    - constant.bool: "\\b(true|false)\\b"
    - constant: "\\b(nothing|missing)\\b"
      # built-in attributes
    - constant: "__[A-Za-z0-9_]+__"
      # definitions
    - identifier: "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
      # keywords
    - statement: "\\b(baremodule|begin|break|catch|const|continue|do|else|elseif|end|export|finally|for|function|global|if|import|let|local|macro|module|public|quote|return|struct|try|using|while)\\b"
    - statement: "\\b(abstract\\s+type|primitive\\s+type|mutable\\s+struct)\\b"
      # decorators
    - identifier.macro: "@[A-Za-z0-9_]+"
      # operators
    - symbol.operator: "[:+*|=!%~<>/\\-?&\\\\รทโˆˆโˆ‰โˆ˜]|\\b(in|isa|where)\\b"
      # for some reason having ^ in the same regex with the other operators broke things
    - symbol.operator: "\\^"
      # parentheses
    - symbol.brackets: "([(){}]|\\[|\\])"
      # numbers
    - constant.number: "\\b([0-9]+(_[0-9]+)*|0x[0-9a-fA-F]+(_[0-9a-fA-F]+)*|0b[01]+(_[01]+)*|0o[0-7]+(_[0-7]+)*|Inf(16|32|64)?|NaN(16|32|64)?)\\b"

    - constant.string:
        start: "\"\"\""
        end: "\"\"\""
        rules: []

    - constant.string:
        start: "\""
        end: "\""
        skip: "\\\\."
        rules:
            - constant.specialChar: "\\\\([\"'abfnrtv\\\\]|[0-3]?[0-7]{1,2}|x[0-9A-Fa-f]{1,2}|u[0-9A-Fa-f]{1,4}|U[0-9A-Fa-f]{1,8})"

    # Lifted from Rust's syntax highlighting
    - constant.string: "'(\\\\.|.)'"
    - constant.string:
        start: "'\""
        end: "'"
        rules: []

    - comment:
        start: "#="
        end: "=#"
        rules: []

    - comment:
        start: "#"
        end: "$"
        rules: []