summaryrefslogtreecommitdiffstats
path: root/public/prism/prism-ada.min.js
blob: 89bd41f3f25a2c1dd2c2ce52499f32a1872da3e3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
Prism.languages.ada = {
  comment: /--.*/,
  string: /"(?:""|[^"\r\f\n])*"/,
  number: [
    {
      pattern:
        /\b\d(?:_?\d)*#[\dA-F](?:_?[\dA-F])*(?:\.[\dA-F](?:_?[\dA-F])*)?#(?:E[+-]?\d(?:_?\d)*)?/i,
    },
    { pattern: /\b\d(?:_?\d)*(?:\.\d(?:_?\d)*)?(?:E[+-]?\d(?:_?\d)*)?\b/i },
  ],
  'attr-name': /\b'\w+/,
  keyword:
    /\b(?:abort|abs|abstract|accept|access|aliased|all|and|array|at|begin|body|case|constant|declare|delay|delta|digits|do|else|elsif|end|entry|exception|exit|for|function|generic|goto|if|in|interface|is|limited|loop|mod|new|not|null|of|others|out|overriding|package|pragma|private|procedure|protected|raise|range|record|rem|renames|requeue|return|reverse|select|separate|some|subtype|synchronized|tagged|task|terminate|then|type|until|use|when|while|with|xor)\b/i,
  boolean: /\b(?:false|true)\b/i,
  operator: /<[=>]?|>=?|=>?|:=|\/=?|\*\*?|[&+-]/,
  punctuation: /\.\.?|[,;():]/,
  char: /'.'/,
  variable: /\b[a-z](?:\w)*\b/i,
};
: { pattern: /^(L)(?:(?:\w+|`[^`\r\n]*`)\/)+/, lookbehind: !0, inside: { punctuation: /\// }, }, builtin: /^L/, }, }, builtin: [ { pattern: /([();\[])[BCDFIJSVZ]+/, lookbehind: !0 }, { pattern: /([\w$>]:)[BCDFIJSVZ]/, lookbehind: !0 }, ], keyword: [ { pattern: /(\.end\s+)[\w-]+/, lookbehind: !0 }, { pattern: /(^|[^\w.-])\.(?!\d)[\w-]+/, lookbehind: !0 }, { pattern: /(^|[^\w.-])(?:abstract|annotation|bridge|constructor|enum|final|interface|private|protected|public|runtime|static|synthetic|system|transient)(?![\w.-])/, lookbehind: !0, }, ], function: { pattern: /(^|[^\w.-])(?:\w+|<[\w$-]+>)(?=\()/, lookbehind: !0 }, field: { pattern: /[\w$]+(?=:)/, alias: 'variable' }, register: { pattern: /(^|[^\w.-])[vp]\d(?![\w.-])/, lookbehind: !0, alias: 'variable', }, boolean: { pattern: /(^|[^\w.-])(?:false|true)(?![\w.-])/, lookbehind: !0 }, number: { pattern: /(^|[^/\w.-])-?(?:NAN|INFINITY|0x(?:[\dA-F]+(?:\.[\dA-F]*)?|\.[\dA-F]+)(?:p[+-]?[\dA-F]+)?|(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?)[dflst]?(?![\w.-])/i, lookbehind: !0, }, label: { pattern: /(:)\w+/, lookbehind: !0, alias: 'property' }, operator: /->|\.\.|[\[=]/, punctuation: /[{}(),;:]/, };