{ "fileTypes": [ "st" ], "foldingStartMarker": "\\[", "foldingStopMarker": "^\\s*\\]|^\\s\\]", "keyEquivalent": "^~S", "name": "Smalltalk", "patterns": [ { "match": "\\b(super|self|yourself|new|extend|class|Smalltalk)\\b", "name": "keyword.language.smalltalk" }, { "match": ":=", "name": "keyword.operator.assignment.smalltalk" }, { "comment": "Parse the variable declaration like: |a b c|", "match": "/^:\\w*\\s*\\|/", "name": "constant.other.block.smalltalk" }, { "captures": { "1": { "name": "punctuation.separator.variable.smalltalk" }, "2": { "name": "support.type.variable.declaration.smalltalk" }, "3": { "name": "punctuation.separator.variable.smalltalk" } }, "match": "(\\|)+([\\w\\ ]+)+(\\|)" }, { "captures": { "1": { "name": "entity.name.function.block.smalltalk" } }, "comment": "Parse the blocks like: [ :a :b | ...... ]", "match": "\\[\\s{0,}(:{1,}[\\w\\ ]+.*\\|)" }, { "match": "<(?!<|=)|>(?!<|=|>)|<=|>=|=|==|~=|~~|>>|\\^", "name": "keyword.operator.comparison.smalltalk" }, { "match": "(\\*|\\+|\\-|/|\\\\)", "name": "keyword.operator.arithmetic.smalltalk" }, { "match": "(?<=[ \\t])!+|\\bnot\\b|&|\\band\\b|\\||\\bor\\b", "name": "keyword.operator.logical.smalltalk" }, { "comment": "Fake reserved word -> main Smalltalk messages", "match": "(?[a-zA-Z_]\\w*(?>[?!])?)(:)(?!:)", "name": "constant.other.messages.smalltalk" }, { "comment": "symbols", "match": "#[a-zA-Z_][a-zA-Z0-9_:]*", "name": "constant.other.symbol.smalltalk" }, { "begin": "#\\[", "comment": "ByteArray Constructor. Unfortunely this dont validate only numbers. TODO.", "end": "\\]", "name": "constant.other.bytearray.smalltalk" }, { "begin": "#\\(", "comment": "Array Constructor", "end": "\\)", "name": "constant.other.array.smalltalk" }, { "begin": "'", "end": "'", "name": "string.smalltalk" }, { "match": "\\b(0[xX]\\h(?>_?\\h)*|\\d(?>_?\\d)*(\\.(?![^[:space:][:digit:]])(?>_?\\d)*)?([eE][-+]?\\d(?>_?\\d)*)?|0[bB][01]+)\\b", "name": "constant.numeric.smalltalk" }, { "match": "\\b[A-Z]\\w*\\b", "name": "variable.other.constant.smalltalk" } ], "scopeName": "source.smalltalk", "uuid": "1ED64A34-BCB1-44E1-A0FE-84053003E232" }