File: solidity.yaml

package info (click to toggle)
micro 2.0.15-1
  • links: PTS, VCS
  • area: main
  • in suites: forky
  • size: 2,828 kB
  • sloc: sh: 247; makefile: 77; xml: 53
file content (41 lines) | stat: -rw-r--r-- 1,641 bytes parent folder | download | duplicates (3)
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
filetype: solidity

detect:
    filename: "\\.sol$"

rules:
    - preproc: "\\b(contract|library|pragma)\\b"
    - constant.number: "\\b[-]?([0-9]+|0x[0-9a-fA-F]+)\\b"
    - identifier: "[a-zA-Z][_a-zA-Z0-9]*[[:space:]]*"
    - statement: "\\b(assembly|break|continue|do|for|function|if|else|new|return|returns|while)\\b"
    - special: "\\b(\\.send|throw)\\b" # make sure they are very visible
    - type.keyword: "\\b(anonymous|constant|indexed|payable|public|private|external|internal)\\b"
    - constant: "\\b(block(\\.(blockhash|coinbase|difficulty|gaslimit|number|timestamp))?|msg(\\.(data|gas|sender|value))?|now|tx(\\.(gasprice|origin))?)\\b"
    - constant: "\\b(keccak256|sha3|sha256|ripemd160|ecrecover|addmod|mulmod|this|super|selfdestruct|\\.balance)\\b"
    - constant: "\\b(true|false)\\b"
    - constant: "\\b(wei|szabo|finney|ether|seconds|minutes|hours|days|weeks|years)\\b"
    - type: "\\b(address|bool|mapping|string|var|int(\\d*)|uint(\\d*)|byte(\\d*)|fixed(\\d*)|ufixed(\\d*))\\b"
    - error: "\\b(abstract|after|case|catch|default|final|in|inline|interface|let|match|null|of|pure|relocatable|static|switch|try|type|typeof|view)\\b"
    - operator: "[-+/*=<>!~%?:&|]"
    - comment:
        start: "//"
        end: "$"
        rules: []
    - comment:
        start: "/\\*"
        end: "\\*/"
        rules: []
    - todo: "TODO:?"
    - constant.string:
        start: "\""
        end: "\""
        skip: "\\\\."
        rules:
            - constant.specialChar: "\\\\."
    - constant.string:
        start: "'"
        end: "'"
        skip: "\\\\."
        rules:
            - constant.specialChar: "\\\\."