| { |
| "$schema": "https://raw.githubusercontent.com/martinring/tmlanguage/master/tmlanguage.json", |
| "name": "FIDL", |
| "scopeName": "source.fidl", |
| "patterns": [ |
| { |
| "include": "#comments" |
| }, |
| { |
| "include": "#attributes" |
| }, |
| { |
| "name": "meta.library.fidl", |
| "match": "\\b(library)\\b\\s*(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*)\\s*(;)", |
| "captures": { |
| "1": { |
| "name": "keyword.control" |
| }, |
| "2": { |
| "name": "entity.name.type" |
| }, |
| "3": { |
| "name": "punctuation.terminator" |
| } |
| } |
| }, |
| { |
| "name": "meta.library.fidl", |
| "match": "\\b(using)\\b\\s*(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*)\\s*(;)", |
| "captures": { |
| "1": { |
| "name": "keyword.control" |
| }, |
| "2": { |
| "name": "entity.name.type" |
| }, |
| "3": { |
| "name": "punctuation.terminator" |
| } |
| } |
| }, |
| { |
| "name": "meta.library.fidl", |
| "match": "\\b(using)\\b\\s*(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*)\\s*\\b(as)\\b\\s*(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)\\s*(;)", |
| "captures": { |
| "1": { |
| "name": "keyword.control" |
| }, |
| "2": { |
| "name": "entity.name.type" |
| }, |
| "3": { |
| "name": "keyword.control" |
| }, |
| "4": { |
| "name": "entity.name.type" |
| }, |
| "5": { |
| "name": "punctuation.terminator" |
| } |
| } |
| }, |
| { |
| "name": "meta.type-alias.fidl", |
| "match": "\\b(alias)\\b\\s*(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)\\s*(=)\\s*(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*)\\s*(?::\\s*(?:((?:(?:(-?\\b(?:(?:0(?:x|X)[0-9a-fA-F]*)|(?:0(?:b|B)[01]*)|(?:(?:[0-9]+\\.?[0-9]*)|(?:\\.[0-9]+))(?:(?:e|E)(?:\\+|-)?[0-9]+)?)\\b)|(\\b(?:true|false)\\b)|(\"(?:[^\\\"]|\\.)*\"))|\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*))|(<)\\s*(?:((?:(?:(-?\\b(?:(?:0(?:x|X)[0-9a-fA-F]*)|(?:0(?:b|B)[01]*)|(?:(?:[0-9]+\\.?[0-9]*)|(?:\\.[0-9]+))(?:(?:e|E)(?:\\+|-)?[0-9]+)?)\\b)|(\\b(?:true|false)\\b)|(\"(?:[^\\\"]|\\.)*\"))|\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*)))(?:,\\s*((?:(?:(-?\\b(?:(?:0(?:x|X)[0-9a-fA-F]*)|(?:0(?:b|B)[01]*)|(?:(?:[0-9]+\\.?[0-9]*)|(?:\\.[0-9]+))(?:(?:e|E)(?:\\+|-)?[0-9]+)?)\\b)|(\\b(?:true|false)\\b)|(\"(?:[^\\\"]|\\.)*\"))|\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*)))*\\s*(>)))?", |
| "captures": { |
| "1": { |
| "name": "keyword.control" |
| }, |
| "2": { |
| "name": "variable.alias" |
| }, |
| "3": { |
| "name": "punctuation.separator" |
| }, |
| "4": { |
| "name": "entity.name.type" |
| }, |
| "5": { |
| "name": "storage.type.constraint" |
| }, |
| "6": { |
| "name": "constant.numeric" |
| }, |
| "7": { |
| "name": "constant.language" |
| }, |
| "8": { |
| "name": "string.quoted.double" |
| }, |
| "9": { |
| "name": "punctuation.bracket.angle" |
| }, |
| "10": { |
| "name": "storage.type.constraint" |
| }, |
| "11": { |
| "name": "constant.numeric" |
| }, |
| "12": { |
| "name": "constant.language" |
| }, |
| "13": { |
| "name": "string.quoted.double" |
| }, |
| "14": { |
| "name": "storage.type.constraint" |
| }, |
| "15": { |
| "name": "constant.numeric" |
| }, |
| "16": { |
| "name": "constant.language" |
| }, |
| "17": { |
| "name": "string.quoted.double" |
| }, |
| "18": { |
| "name": "punctuation.bracket.angle" |
| } |
| } |
| }, |
| { |
| "name": "meta.const.fidl", |
| "begin": "\\b(const)\\b\\s*(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)\\s*((?:\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*|(\\b(?:bool|float32|float64|int8|int16|int32|int64|uint8|uint16|uint32|uint64)\\b)))\\s*(=)", |
| "beginCaptures": { |
| "1": { |
| "name": "keyword.control" |
| }, |
| "2": { |
| "name": "variable.constant" |
| }, |
| "3": { |
| "name": "storage.type" |
| }, |
| "4": { |
| "name": "storage.type.basic" |
| }, |
| "5": { |
| "name": "punctuation.separator" |
| } |
| }, |
| "end": "(;)", |
| "endCaptures": { |
| "1": { |
| "name": "punctuation.terminator" |
| } |
| }, |
| "patterns": [ |
| { |
| "include": "#const-value" |
| } |
| ] |
| }, |
| { |
| "name": "meta.protocol-block.fidl", |
| "begin": "\\b(protocol)\\b\\s*(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)\\s*{", |
| "beginCaptures": { |
| "1": { |
| "name": "keyword.control" |
| }, |
| "2": { |
| "name": "entity.name.type" |
| } |
| }, |
| "end": "}", |
| "endCaptures": {}, |
| "patterns": [ |
| { |
| "include": "#comments" |
| }, |
| { |
| "include": "#attributes" |
| }, |
| { |
| "match": "\\b(compose)\\b\\s*(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*)", |
| "captures": { |
| "1": { |
| "name": "keyword.control" |
| }, |
| "2": { |
| "name": "entity.name.type" |
| } |
| } |
| }, |
| { |
| "include": "#method" |
| } |
| ] |
| }, |
| { |
| "name": "meta.type.fidl", |
| "begin": "\\b(type)\\b\\s*(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)\\s*(=)", |
| "beginCaptures": { |
| "1": { |
| "name": "keyword.control" |
| }, |
| "2": { |
| "name": "entity.name.type" |
| }, |
| "3": { |
| "name": "punctuation.separator" |
| } |
| }, |
| "end": "(;)", |
| "endCaptures": { |
| "1": { |
| "name": "punctuation.terminator" |
| } |
| }, |
| "patterns": [ |
| { |
| "include": "#type-constructor" |
| } |
| ] |
| } |
| ], |
| "repository": { |
| "comments": { |
| "patterns": [ |
| { |
| "name": "invalid.illegal.stray-comment-end.fidl", |
| "match": "\\*/.*\\n", |
| "captures": {} |
| }, |
| { |
| "name": "comment.line.documentation.fidl", |
| "match": "///.*\\n", |
| "captures": {} |
| }, |
| { |
| "name": "comment.line.double-slash.fidl", |
| "match": "//.*\\n", |
| "captures": {} |
| } |
| ] |
| }, |
| "attribute-with-args": { |
| "patterns": [ |
| { |
| "name": "meta.attribute.with-args.fidl", |
| "begin": "(@\\s*\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)\\s*\\(", |
| "beginCaptures": { |
| "1": { |
| "name": "entity.other.attribute-name" |
| } |
| }, |
| "end": "\\)", |
| "endCaptures": {}, |
| "patterns": [ |
| { |
| "match": "(?:(,))?\\s*\\b[a-zA-Z_][0-9a-zA-Z_]*\\b\\s*(=)", |
| "captures": { |
| "1": { |
| "name": "punctuation.separator" |
| }, |
| "2": { |
| "name": "punctuation.separator" |
| } |
| } |
| }, |
| { |
| "include": "#const-value" |
| } |
| ] |
| } |
| ] |
| }, |
| "attribute-no-args": { |
| "patterns": [ |
| { |
| "name": "meta.attribute.no-args.fidl", |
| "match": "(@\\s*\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)", |
| "captures": { |
| "1": { |
| "name": "entity.other.attribute-name" |
| } |
| } |
| } |
| ] |
| }, |
| "attributes": { |
| "patterns": [ |
| { |
| "include": "#attribute-with-args" |
| }, |
| { |
| "include": "#attribute-no-args" |
| } |
| ] |
| }, |
| "method": { |
| "patterns": [ |
| { |
| "name": "meta.method.fidl", |
| "begin": "(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)", |
| "beginCaptures": { |
| "1": { |
| "name": "entity.name.function" |
| } |
| }, |
| "end": "(?:\\b(error)\\b\\s*(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*))?\\s*(;)", |
| "endCaptures": { |
| "1": { |
| "name": "keyword.control" |
| }, |
| "2": { |
| "name": "entity.name.type" |
| }, |
| "3": { |
| "name": "punctuation.terminator" |
| } |
| }, |
| "patterns": [ |
| { |
| "include": "#method-argument" |
| }, |
| { |
| "match": "(->)", |
| "captures": { |
| "1": { |
| "name": "punctuation.separator" |
| } |
| } |
| } |
| ] |
| } |
| ] |
| }, |
| "const-value": { |
| "patterns": [ |
| { |
| "name": "meta.separator.fidl", |
| "match": "(\\|)", |
| "captures": { |
| "1": { |
| "name": "punctuation.separator" |
| } |
| } |
| }, |
| { |
| "name": "storage.type.operand.fidl", |
| "match": "(?:(?:(-?\\b(?:(?:0(?:x|X)[0-9a-fA-F]*)|(?:0(?:b|B)[01]*)|(?:(?:[0-9]+\\.?[0-9]*)|(?:\\.[0-9]+))(?:(?:e|E)(?:\\+|-)?[0-9]+)?)\\b)|(\\b(?:true|false)\\b)|(\"(?:[^\\\"]|\\.)*\"))|\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*)", |
| "captures": { |
| "1": { |
| "name": "constant.numeric" |
| }, |
| "2": { |
| "name": "constant.language" |
| }, |
| "3": { |
| "name": "string.quoted.double" |
| } |
| } |
| } |
| ] |
| }, |
| "numeric-const-value": { |
| "patterns": [ |
| { |
| "name": "meta.separator.fidl", |
| "match": "(\\|)", |
| "captures": { |
| "1": { |
| "name": "punctuation.separator" |
| } |
| } |
| }, |
| { |
| "name": "storage.type.operand.fidl", |
| "match": "(?:(-?\\b(?:(?:0(?:x|X)[0-9a-fA-F]*)|(?:0(?:b|B)[01]*)|(?:(?:[0-9]+\\.?[0-9]*)|(?:\\.[0-9]+))(?:(?:e|E)(?:\\+|-)?[0-9]+)?)\\b)|\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*)", |
| "captures": { |
| "1": { |
| "name": "constant.numeric" |
| } |
| } |
| } |
| ] |
| }, |
| "default-value": { |
| "patterns": [ |
| { |
| "name": "meta.separator.fidl", |
| "match": "(=)", |
| "captures": { |
| "1": { |
| "name": "punctuation.separator" |
| } |
| } |
| }, |
| { |
| "include": "#const-value" |
| } |
| ] |
| }, |
| "method-argument": { |
| "patterns": [ |
| { |
| "name": "meta.method.arguments.fidl", |
| "begin": "\\(", |
| "beginCaptures": {}, |
| "end": "\\)", |
| "endCaptures": {}, |
| "patterns": [ |
| { |
| "include": "#type-constructor" |
| } |
| ] |
| } |
| ] |
| }, |
| "type-constructor": { |
| "patterns": [ |
| { |
| "include": "#type-constructor-inline" |
| }, |
| { |
| "include": "#type-constructor-inline-arg" |
| }, |
| { |
| "include": "#type-constructor-reference" |
| } |
| ] |
| }, |
| "type-constructor-inline": { |
| "patterns": [ |
| { |
| "name": "meta.type-constructor-inline.fidl", |
| "begin": "((?:(?:\\bstrict\\b|\\bflexible\\b|\\bresource\\b)\\s*)*)\\s*(?:\\b(union)\\b|\\b(struct)\\b|\\b(table)\\b|\\b(enum)\\b|\\b(bits)\\b)\\s*(?:(:)\\s*(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*))?\\s*{", |
| "beginCaptures": { |
| "1": { |
| "name": "storage.type.modifier" |
| }, |
| "2": { |
| "name": "keyword.control" |
| }, |
| "3": { |
| "name": "keyword.control" |
| }, |
| "4": { |
| "name": "keyword.control" |
| }, |
| "5": { |
| "name": "keyword.control" |
| }, |
| "6": { |
| "name": "keyword.control" |
| }, |
| "7": { |
| "name": "punctuation.separator" |
| }, |
| "8": { |
| "name": "entity.name.type" |
| } |
| }, |
| "end": "}\\s*(?::\\s*(?:((?:(?:(-?\\b(?:(?:0(?:x|X)[0-9a-fA-F]*)|(?:0(?:b|B)[01]*)|(?:(?:[0-9]+\\.?[0-9]*)|(?:\\.[0-9]+))(?:(?:e|E)(?:\\+|-)?[0-9]+)?)\\b)|(\\b(?:true|false)\\b)|(\"(?:[^\\\"]|\\.)*\"))|\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*))|(<)\\s*(?:((?:(?:(-?\\b(?:(?:0(?:x|X)[0-9a-fA-F]*)|(?:0(?:b|B)[01]*)|(?:(?:[0-9]+\\.?[0-9]*)|(?:\\.[0-9]+))(?:(?:e|E)(?:\\+|-)?[0-9]+)?)\\b)|(\\b(?:true|false)\\b)|(\"(?:[^\\\"]|\\.)*\"))|\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*)))(?:,\\s*((?:(?:(-?\\b(?:(?:0(?:x|X)[0-9a-fA-F]*)|(?:0(?:b|B)[01]*)|(?:(?:[0-9]+\\.?[0-9]*)|(?:\\.[0-9]+))(?:(?:e|E)(?:\\+|-)?[0-9]+)?)\\b)|(\\b(?:true|false)\\b)|(\"(?:[^\\\"]|\\.)*\"))|\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*)))*\\s*(>)))?", |
| "endCaptures": { |
| "1": { |
| "name": "storage.type.constraint" |
| }, |
| "2": { |
| "name": "constant.numeric" |
| }, |
| "3": { |
| "name": "constant.language" |
| }, |
| "4": { |
| "name": "string.quoted.double" |
| }, |
| "5": { |
| "name": "punctuation.bracket.angle" |
| }, |
| "6": { |
| "name": "storage.type.constraint" |
| }, |
| "7": { |
| "name": "constant.numeric" |
| }, |
| "8": { |
| "name": "constant.language" |
| }, |
| "9": { |
| "name": "string.quoted.double" |
| }, |
| "10": { |
| "name": "storage.type.constraint" |
| }, |
| "11": { |
| "name": "constant.numeric" |
| }, |
| "12": { |
| "name": "constant.language" |
| }, |
| "13": { |
| "name": "string.quoted.double" |
| }, |
| "14": { |
| "name": "punctuation.bracket.angle" |
| } |
| }, |
| "patterns": [ |
| { |
| "include": "#comments" |
| }, |
| { |
| "include": "#attributes" |
| }, |
| { |
| "include": "#layout-member" |
| } |
| ] |
| } |
| ] |
| }, |
| "type-constructor-inline-arg": { |
| "patterns": [ |
| { |
| "name": "meta.type-constructor-inline-arg.fidl", |
| "begin": "(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*)\\s*<\\s*((?:(?:\\bstrict\\b|\\bflexible\\b|\\bresource\\b)\\s*)*)\\s*(?:\\b(union)\\b|\\b(struct)\\b|\\b(table)\\b|\\b(enum)\\b|\\b(bits)\\b)\\s*(?:(:)\\s*(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*))?\\s*{", |
| "beginCaptures": { |
| "1": { |
| "name": "entity.name.type" |
| }, |
| "2": { |
| "name": "storage.type.modifier" |
| }, |
| "3": { |
| "name": "keyword.control" |
| }, |
| "4": { |
| "name": "keyword.control" |
| }, |
| "5": { |
| "name": "keyword.control" |
| }, |
| "6": { |
| "name": "keyword.control" |
| }, |
| "7": { |
| "name": "keyword.control" |
| }, |
| "8": { |
| "name": "punctuation.separator" |
| }, |
| "9": { |
| "name": "entity.name.type" |
| } |
| }, |
| "end": "(?:,\\s*(?:(?:(-?\\b(?:(?:0(?:x|X)[0-9a-fA-F]*)|(?:0(?:b|B)[01]*)|(?:(?:[0-9]+\\.?[0-9]*)|(?:\\.[0-9]+))(?:(?:e|E)(?:\\+|-)?[0-9]+)?)\\b)|(\\b(?:true|false)\\b)|(\"(?:[^\\\"]|\\.)*\"))|\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*))?\\s*>\\s*(?::\\s*(?:((?:(?:(-?\\b(?:(?:0(?:x|X)[0-9a-fA-F]*)|(?:0(?:b|B)[01]*)|(?:(?:[0-9]+\\.?[0-9]*)|(?:\\.[0-9]+))(?:(?:e|E)(?:\\+|-)?[0-9]+)?)\\b)|(\\b(?:true|false)\\b)|(\"(?:[^\\\"]|\\.)*\"))|\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*))|(<)\\s*(?:((?:(?:(-?\\b(?:(?:0(?:x|X)[0-9a-fA-F]*)|(?:0(?:b|B)[01]*)|(?:(?:[0-9]+\\.?[0-9]*)|(?:\\.[0-9]+))(?:(?:e|E)(?:\\+|-)?[0-9]+)?)\\b)|(\\b(?:true|false)\\b)|(\"(?:[^\\\"]|\\.)*\"))|\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*)))(?:,\\s*((?:(?:(-?\\b(?:(?:0(?:x|X)[0-9a-fA-F]*)|(?:0(?:b|B)[01]*)|(?:(?:[0-9]+\\.?[0-9]*)|(?:\\.[0-9]+))(?:(?:e|E)(?:\\+|-)?[0-9]+)?)\\b)|(\\b(?:true|false)\\b)|(\"(?:[^\\\"]|\\.)*\"))|\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*)))*\\s*(>)))?", |
| "endCaptures": { |
| "1": { |
| "name": "constant.numeric" |
| }, |
| "2": { |
| "name": "constant.language" |
| }, |
| "3": { |
| "name": "string.quoted.double" |
| }, |
| "4": { |
| "name": "storage.type.constraint" |
| }, |
| "5": { |
| "name": "constant.numeric" |
| }, |
| "6": { |
| "name": "constant.language" |
| }, |
| "7": { |
| "name": "string.quoted.double" |
| }, |
| "8": { |
| "name": "punctuation.bracket.angle" |
| }, |
| "9": { |
| "name": "storage.type.constraint" |
| }, |
| "10": { |
| "name": "constant.numeric" |
| }, |
| "11": { |
| "name": "constant.language" |
| }, |
| "12": { |
| "name": "string.quoted.double" |
| }, |
| "13": { |
| "name": "storage.type.constraint" |
| }, |
| "14": { |
| "name": "constant.numeric" |
| }, |
| "15": { |
| "name": "constant.language" |
| }, |
| "16": { |
| "name": "string.quoted.double" |
| }, |
| "17": { |
| "name": "punctuation.bracket.angle" |
| } |
| }, |
| "patterns": [ |
| { |
| "include": "#comments" |
| }, |
| { |
| "include": "#attributes" |
| }, |
| { |
| "include": "#layout-member" |
| } |
| ] |
| } |
| ] |
| }, |
| "type-constructor-reference": { |
| "patterns": [ |
| { |
| "name": "meta.type-constructor-reference.fidl", |
| "match": "(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*)\\s*(?:(<)\\s*(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*)\\s*(?:(,)\\s*(?:(-?\\b(?:(?:0(?:x|X)[0-9a-fA-F]*)|(?:0(?:b|B)[01]*)|(?:(?:[0-9]+\\.?[0-9]*)|(?:\\.[0-9]+))(?:(?:e|E)(?:\\+|-)?[0-9]+)?)\\b)|\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*))?\\s*(>))?\\s*(?::\\s*(?:((?:(?:(-?\\b(?:(?:0(?:x|X)[0-9a-fA-F]*)|(?:0(?:b|B)[01]*)|(?:(?:[0-9]+\\.?[0-9]*)|(?:\\.[0-9]+))(?:(?:e|E)(?:\\+|-)?[0-9]+)?)\\b)|(\\b(?:true|false)\\b)|(\"(?:[^\\\"]|\\.)*\"))|\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*))|(<)\\s*(?:((?:(?:(-?\\b(?:(?:0(?:x|X)[0-9a-fA-F]*)|(?:0(?:b|B)[01]*)|(?:(?:[0-9]+\\.?[0-9]*)|(?:\\.[0-9]+))(?:(?:e|E)(?:\\+|-)?[0-9]+)?)\\b)|(\\b(?:true|false)\\b)|(\"(?:[^\\\"]|\\.)*\"))|\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*)))(?:,\\s*((?:(?:(-?\\b(?:(?:0(?:x|X)[0-9a-fA-F]*)|(?:0(?:b|B)[01]*)|(?:(?:[0-9]+\\.?[0-9]*)|(?:\\.[0-9]+))(?:(?:e|E)(?:\\+|-)?[0-9]+)?)\\b)|(\\b(?:true|false)\\b)|(\"(?:[^\\\"]|\\.)*\"))|\\b[a-zA-Z_][0-9a-zA-Z_]*\\b(?:\\.\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)*)))*\\s*(>)))?", |
| "captures": { |
| "1": { |
| "name": "entity.name.type" |
| }, |
| "2": { |
| "name": "punctuation.bracket.angle" |
| }, |
| "3": { |
| "name": "entity.name.type" |
| }, |
| "4": { |
| "name": "punctuation.separator" |
| }, |
| "5": { |
| "name": "constant.numeric" |
| }, |
| "6": { |
| "name": "punctuation.bracket.angle" |
| }, |
| "7": { |
| "name": "storage.type.constraint" |
| }, |
| "8": { |
| "name": "constant.numeric" |
| }, |
| "9": { |
| "name": "constant.language" |
| }, |
| "10": { |
| "name": "string.quoted.double" |
| }, |
| "11": { |
| "name": "punctuation.bracket.angle" |
| }, |
| "12": { |
| "name": "storage.type.constraint" |
| }, |
| "13": { |
| "name": "constant.numeric" |
| }, |
| "14": { |
| "name": "constant.language" |
| }, |
| "15": { |
| "name": "string.quoted.double" |
| }, |
| "16": { |
| "name": "storage.type.constraint" |
| }, |
| "17": { |
| "name": "constant.numeric" |
| }, |
| "18": { |
| "name": "constant.language" |
| }, |
| "19": { |
| "name": "string.quoted.double" |
| }, |
| "20": { |
| "name": "punctuation.bracket.angle" |
| } |
| } |
| } |
| ] |
| }, |
| "layout-member": { |
| "patterns": [ |
| { |
| "include": "#layout-member-reserved" |
| }, |
| { |
| "include": "#layout-member-value" |
| }, |
| { |
| "include": "#layout-member-struct" |
| }, |
| { |
| "include": "#layout-member-ordinaled" |
| } |
| ] |
| }, |
| "layout-member-reserved": { |
| "patterns": [ |
| { |
| "name": "meta.layout.reserved-member.fidl", |
| "match": "(-?\\b(?:(?:0(?:x|X)[0-9a-fA-F]*)|(?:0(?:b|B)[01]*)|(?:(?:[0-9]+\\.?[0-9]*)|(?:\\.[0-9]+))(?:(?:e|E)(?:\\+|-)?[0-9]+)?)\\b)\\s*(:)\\s*\\b(reserved)\\b\\s*(;)", |
| "captures": { |
| "1": { |
| "name": "constant.numeric" |
| }, |
| "2": { |
| "name": "punctuation.separator" |
| }, |
| "3": { |
| "name": "keyword.control" |
| }, |
| "4": { |
| "name": "punctuation.terminator" |
| } |
| } |
| } |
| ] |
| }, |
| "layout-member-ordinaled": { |
| "patterns": [ |
| { |
| "name": "meta.layout.ordinaled-member.fidl", |
| "begin": "(-?\\b(?:(?:0(?:x|X)[0-9a-fA-F]*)|(?:0(?:b|B)[01]*)|(?:(?:[0-9]+\\.?[0-9]*)|(?:\\.[0-9]+))(?:(?:e|E)(?:\\+|-)?[0-9]+)?)\\b)\\s*(:)\\s*(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)", |
| "beginCaptures": { |
| "1": { |
| "name": "constant.numeric" |
| }, |
| "2": { |
| "name": "punctuation.separator" |
| }, |
| "3": { |
| "name": "variable" |
| } |
| }, |
| "end": "(;)", |
| "endCaptures": { |
| "1": { |
| "name": "punctuation.terminator" |
| } |
| }, |
| "patterns": [ |
| { |
| "include": "#type-constructor" |
| } |
| ] |
| } |
| ] |
| }, |
| "layout-member-struct": { |
| "patterns": [ |
| { |
| "name": "meta.layout.struct-struct-member.fidl", |
| "begin": "(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)", |
| "beginCaptures": { |
| "1": { |
| "name": "variable" |
| } |
| }, |
| "end": "(;)", |
| "endCaptures": { |
| "1": { |
| "name": "punctuation.terminator" |
| } |
| }, |
| "patterns": [ |
| { |
| "include": "#type-constructor" |
| }, |
| { |
| "include": "#default-value" |
| } |
| ] |
| } |
| ] |
| }, |
| "layout-member-value": { |
| "patterns": [ |
| { |
| "name": "meta.layout.value-member.fidl", |
| "begin": "(\\b[a-zA-Z_][0-9a-zA-Z_]*\\b)\\s*(=)", |
| "beginCaptures": { |
| "1": { |
| "name": "variable" |
| }, |
| "2": { |
| "name": "punctuation.separator" |
| } |
| }, |
| "end": "(;)", |
| "endCaptures": { |
| "1": { |
| "name": "punctuation.terminator" |
| } |
| }, |
| "patterns": [ |
| { |
| "include": "#numeric-const-value" |
| } |
| ] |
| } |
| ] |
| } |
| } |
| } |