We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
(identifier) @variable (self) @variable.builtin (super) @variable.builtin (strong) @variable.builtin (nonatomic) @variable.builtin (weak) @variable.builtin
[ "in" "@interface" "@protocol" "@Property" "@EnD" "@implementation" "const" "default" "enum" "extern" "inline" "static" "struct" "typedef" "union" "volatile" "goto" "register" ] @Keyword
"sizeof" @keyword.operator "return" @keyword.return
[ "while" "for" "do" "continue" "break" ] @repeat
[ "if" "else" "case" "switch" ] @conditional
"#define" @constant.macro [ "#if" "#ifdef" "#ifndef" "#else" "#elif" "#endif" (preproc_directive) ] @Keyword
"#include" @include "#import" @include
[ "="
"-" "*" "/" "+" "%"
"~" "|" "&" "^" "<<" ">>"
"->"
"<" "<=" ">=" ">" "==" "!="
"!" "&&" "||"
"-=" "+=" "*=" "/=" "%=" "|=" "&=" "^=" ">>=" "<<=" "--" "++" "@" ] @operator
[ (true) (false) ] @boolean
[ "." ";" ":" "," ] @punctuation.delimiter
"..." @punctuation.special
(conditional_expression [ "?" ":" ] @conditional)
[ "(" ")" "[" "]" "{" "}"] @punctuation.bracket
(string_literal) @string (system_lib_string) @string (escape_sequence) @string.escape
(null) @constant.builtin (number_literal) @Number (char_literal) @character
[ (preproc_arg) (preproc_defined) ] @function.macro
(((field_expression (field_identifier) @Property)) @_parent (#not-has-parent? @_parent template_method function_declarator call_expression))
(((field_identifier) @Property) (#has-ancestor? @Property field_declaration) (#not-has-ancestor? @Property function_declarator))
(statement_identifier) @Label
[ (type_identifier) (primitive_type) (sized_type_specifier) (type_descriptor) ] @type
(declaration (type_qualifier) @type) (cast_expression type: (type_descriptor) @type) (sizeof_expression value: (parenthesized_expression (identifier) @type))
((identifier) @constant (#match? @constant "^[A-Z][A-Z0-9_]+$"))
;; Preproc def / undef (preproc_def name: (_) @constant) (preproc_call directive: (preproc_directive) @u argument: () @constant (#eq? @_u "#undef"))
(call_expression function: (identifier) @function) (call_expression function: (field_expression field: (field_identifier) @function)) (function_declarator declarator: (identifier) @function) (preproc_function_def name: (identifier) @function.macro)
(comment) @comment
;; Parameters (parameter_declaration declarator: (identifier) @parameter)
(parameter_declaration declarator: (pointer_declarator) @parameter)
(preproc_params (identifier)) @parameter
[ "attribute" "__cdecl" "__clrcall" "__stdcall" "__fastcall" "__thiscall" "__vectorcall" "_unaligned" "__unaligned" "__declspec" ] @Attribute
(ERROR) @error
The text was updated successfully, but these errors were encountered:
As objc is supper-set of c, we just need append some extendable syntax.
Sorry, something went wrong.
No branches or pull requests
(identifier) @variable
(self) @variable.builtin
(super) @variable.builtin
(strong) @variable.builtin
(nonatomic) @variable.builtin
(weak) @variable.builtin
[
"in"
"@interface"
"@protocol"
"@Property"
"@EnD"
"@implementation"
"const"
"default"
"enum"
"extern"
"inline"
"static"
"struct"
"typedef"
"union"
"volatile"
"goto"
"register"
] @Keyword
"sizeof" @keyword.operator
"return" @keyword.return
[
"while"
"for"
"do"
"continue"
"break"
] @repeat
[
"if"
"else"
"case"
"switch"
] @conditional
"#define" @constant.macro
[
"#if"
"#ifdef"
"#ifndef"
"#else"
"#elif"
"#endif"
(preproc_directive)
] @Keyword
"#include" @include
"#import" @include
[
"="
"-"
"*"
"/"
"+"
"%"
"~"
"|"
"&"
"^"
"<<"
">>"
"->"
"<"
"<="
">="
">"
"=="
"!="
"!"
"&&"
"||"
"-="
"+="
"*="
"/="
"%="
"|="
"&="
"^="
">>="
"<<="
"--"
"++"
"@"
] @operator
[
(true)
(false)
] @boolean
[ "." ";" ":" "," ] @punctuation.delimiter
"..." @punctuation.special
(conditional_expression [ "?" ":" ] @conditional)
[ "(" ")" "[" "]" "{" "}"] @punctuation.bracket
(string_literal) @string
(system_lib_string) @string
(escape_sequence) @string.escape
(null) @constant.builtin
(number_literal) @Number
(char_literal) @character
[
(preproc_arg)
(preproc_defined)
] @function.macro
(((field_expression
(field_identifier) @Property)) @_parent
(#not-has-parent? @_parent template_method function_declarator call_expression))
(((field_identifier) @Property)
(#has-ancestor? @Property field_declaration)
(#not-has-ancestor? @Property function_declarator))
(statement_identifier) @Label
[
(type_identifier)
(primitive_type)
(sized_type_specifier)
(type_descriptor)
] @type
(declaration (type_qualifier) @type)
(cast_expression type: (type_descriptor) @type)
(sizeof_expression value: (parenthesized_expression (identifier) @type))
((identifier) @constant
(#match? @constant "^[A-Z][A-Z0-9_]+$"))
;; Preproc def / undef
(preproc_def
name: (_) @constant)
(preproc_call
directive: (preproc_directive) @u
argument: () @constant
(#eq? @_u "#undef"))
(call_expression
function: (identifier) @function)
(call_expression
function: (field_expression
field: (field_identifier) @function))
(function_declarator
declarator: (identifier) @function)
(preproc_function_def
name: (identifier) @function.macro)
(comment) @comment
;; Parameters
(parameter_declaration
declarator: (identifier) @parameter)
(parameter_declaration
declarator: (pointer_declarator) @parameter)
(preproc_params
(identifier)) @parameter
[
"attribute"
"__cdecl"
"__clrcall"
"__stdcall"
"__fastcall"
"__thiscall"
"__vectorcall"
"_unaligned"
"__unaligned"
"__declspec"
] @Attribute
(ERROR) @error
The text was updated successfully, but these errors were encountered: