Files
code_tool_fly/VSCode-win32-x64-1.74.0/resources/app/extensions/dart/syntaxes/dart.tmLanguage.json
T

1 line
7.0 KiB
JSON
Raw Normal View History

2025-05-09 16:55:09 +08:00
{"information_for_contributors":["This file has been converted from https://github.com/dart-lang/dart-syntax-highlight/blob/master/grammars/dart.json","If you want to provide a fix or improvement, please create a pull request against the original repository.","Once accepted there, we are happy to receive an update request."],"version":"https://github.com/dart-lang/dart-syntax-highlight/commit/bd5cbdfe533c455a7ff7875923c4a94a5b497382","name":"Dart","scopeName":"source.dart","patterns":[{"name":"meta.preprocessor.script.dart","match":"^(#!.*)$"},{"name":"meta.declaration.dart","begin":"^\\w*\\b(library|import|part of|part|export)\\b","beginCaptures":{"0":{"name":"keyword.other.import.dart"}},"end":";","endCaptures":{"0":{"name":"punctuation.terminator.dart"}},"patterns":[{"include":"#strings"},{"include":"#comments"},{"name":"keyword.other.import.dart","match":"\\b(as|show|hide)\\b"},{"name":"keyword.control.dart","match":"\\b(if)\\b"}]},{"include":"#comments"},{"include":"#punctuation"},{"include":"#annotations"},{"include":"#keywords"},{"include":"#constants-and-special-vars"},{"include":"#strings"}],"repository":{"dartdoc":{"patterns":[{"match":"(\\[.*?\\])","captures":{"0":{"name":"variable.name.source.dart"}}},{"match":"^ {4,}(?![ \\*]).*","captures":{"0":{"name":"variable.name.source.dart"}}},{"contentName":"variable.other.source.dart","begin":"```.*?$","end":"```"},{"match":"(`.*?`)","captures":{"0":{"name":"variable.other.source.dart"}}},{"match":"(`.*?`)","captures":{"0":{"name":"variable.other.source.dart"}}},{"match":"(\\* (( ).*))$","captures":{"2":{"name":"variable.other.source.dart"}}}]},"comments":{"patterns":[{"name":"comment.block.empty.dart","match":"/\\*\\*/","captures":{"0":{"name":"punctuation.definition.comment.dart"}}},{"include":"#comments-doc-oldschool"},{"include":"#comments-doc"},{"include":"#comments-inline"}]},"comments-doc-oldschool":{"patterns":[{"name":"comment.block.documentation.dart","begin":"/\\*\\*","end":"\\*/","patterns":[{"include":"#comments-doc-oldschool"},{"include":"#comments-block"},{"include":"#dartdoc"}]}]},"comments-doc":{"patterns":[{"name":"comment.block.documentation.dart","begin":"///","while":"^\\s*///","patterns":[{"include":"#dartdoc"}]}]},"comments-inline":{"patterns":[{"include":"#comments-block"},{"match":"((//).*)$","captures":{"1":{"name":"comment.line.double-slash.dart"}}}]},"comments-block":{"patterns":[{"name":"comment.block.dart","begin":"/\\*","end":"\\*/","patterns":[{"include":"#comments-block"}]}]},"annotations":{"patterns":[{"name":"storage.type.annotation.dart","match":"@[a-zA-Z]+"}]},"constants-and-special-vars":{"patterns":[{"name":"constant.language.dart","match":"(?<!\\$)\\b(true|false|null)\\b(?!\\$)"},{"name":"variable.language.dart","match":"(?<!\\$)\\b(this|super)\\b(?!\\$)"},{"name":"constant.numeric.dart","match":"(?<!\\$)\\b((0(x|X)[0-9a-fA-F]*)|(([0-9]+\\.?[0-9]*)|(\\.[0-9]+))((e|E)(\\+|-)?[0-9]+)?)\\b(?!\\$)"},{"include":"#class-identifier"},{"include":"#function-identifier"}]},"class-identifier":{"patterns":[{"name":"storage.type.primitive.dart","match":"\\bvoid\\b"},{"name":"support.class.dart","match":"\\b(bool|num|int|double|dynamic)\\b"},{"match":"\\b([_$]*[A-Z][a-zA-Z0-9_$]*)(<(?:[a-zA-Z0-9_$<>?]|,\\s*|\\s+extends\\s+)+>)?","captures":{"1":{"name":"support.class.dart"},"2":{"patterns":[{"include":"#type-args"}]}}}]},"function-identifier":{"patterns":[{"match":"([_$]*[a-z][a-zA-Z0-9_$]*)(<(?:[a-zA-Z0-9_$<>?]|,\\s*|\\s+extends\\s+)+>)?[!?]?(\\(|\\s+=>)","captures":{"1":{"name":"entity.name.function.dart"},"2":{"patterns":[{"include":"#type-args"}]}}}]},"type-args":{"begin":"(<)","end":"(>)","beginCaptures":{"1":{"name":"other.source.dart"}},"endCaptures":{"1":{"name":"other.source.dart"}},"patterns":[{"include":"#class-identifier"},{"match":"[\\s,]+"},{"name":"keyword.declaration.dart","match":"extends"}]},"keywords":{"patterns":[{"name":"keyword.cast.dart","match":"(?<!\\$)\\bas\\b(?!\\$)"},{"name":"keyword.control.catch-exception.dart","match":"(?<!\\$)\\b(try|on|catch|finally|throw|rethrow)\\b(?!\\$)"},{"name":"keyword.control.dar