github-linguist/linguist

Outstanding Grammar Issues

Open

#3,924 opened on Nov 30, 2017

View on GitHub
 (42 comments) (2 reactions) (0 assignees)Ruby (5,166 forks)batch import
Help Wanted

Repository metrics

Stars
 (13,466 stars)
PR merge metrics
 (Avg merge 102d 5h) (19 merged PRs in 30d)

Description

The following is a detailed list of all the outstanding issues in the grammars that GitHub.com uses for syntax highlighting the code in our website.

These issues are detected by our grammars compiler (https://github.com/github/linguist/pull/3915) and are probably causing minor rendering bugs in the website.

Help is very much welcome! If you're seeing bugs or rendering issues in your source code in GitHub, please start by taking a look at this list to make sure we're not detecting any issues in your language's grammar.

Feel free to ask any questions about any given issue and what would be the appropriate way to fix it. I'll keep the issue up-to-date as I work through grammar fixes myself.

cc @github/linguist @pchaigno @Alhadis


Last updated: 8 Jun 2026

  • repository vendor/grammars/MATLAB-Language-grammar (from https://github.com/mathworks/MATLAB-Language-grammar) (16 errors)

    • Invalid regex in grammar: source.matlab (in Matlab.tmbundle/Syntaxes/MATLAB.tmLanguage) contains a malformed regex (regex "(?<!\.{3}.*)(?:(?=([,;])(?![^(]*...": lookbehind assertion is not fixed length (at offset 11))
    • Invalid regex in grammar: source.matlab (in Matlab.tmbundle/Syntaxes/MATLAB.tmLanguage) contains a malformed regex (regex "(?<!\.{3}.*)(?:(?=[,;](?![^(]*\)...": lookbehind assertion is not fixed length (at offset 11))
    • Invalid regex in grammar: source.matlab (in Matlab.tmbundle/Syntaxes/MATLAB.tmLanguage) contains a malformed regex (regex "(?<!\.{3}.*)(?:(?=([,;])(?![^(]*...": lookbehind assertion is not fixed length (at offset 11))
    • Invalid regex in grammar: source.matlab (in Matlab.tmbundle/Syntaxes/MATLAB.tmLanguage) contains a malformed regex (regex "(?<!\.{3}.*)(?:(?=([,;])(?![^(]*...": lookbehind assertion is not fixed length (at offset 11))
    • Invalid regex in grammar: source.matlab (in Matlab.tmbundle/Syntaxes/MATLAB.tmLanguage) contains a malformed regex (regex "(?<!\.{3}.*)(?:(?=([,;])(?![^(]*...": lookbehind assertion is not fixed length (at offset 11))
    • Invalid regex in grammar: source.matlab (in Matlab.tmbundle/Syntaxes/MATLAB.tmLanguage) contains a malformed regex (regex "(?<!\.{3}.*)(?:(?=[,;](?![^(]*\)...": lookbehind assertion is not fixed length (at offset 11))
    • Invalid regex in grammar: source.matlab (in Matlab.tmbundle/Syntaxes/MATLAB.tmLanguage) contains a malformed regex (regex "(?<!\.{3}.*)(?:(?=([,;])(?![^(]*...": lookbehind assertion is not fixed length (at offset 11))
    • Invalid regex in grammar: source.matlab (in Matlab.tmbundle/Syntaxes/MATLAB.tmLanguage) contains a malformed regex (regex "(?<!\.{3}.*)(?:(?=[,;](?![^(]*\)...": lookbehind assertion is not fixed length (at offset 11))
    • Invalid regex in grammar: source.matlab (in Matlab.tmbundle/Syntaxes/MATLAB.tmLanguage) contains a malformed regex (regex "(\}|(?<!\.{3}.*)\n)": lookbehind assertion is not fixed length (at offset 15))
    • Invalid regex in grammar: source.matlab (in Matlab.tmbundle/Syntaxes/MATLAB.tmLanguage) contains a malformed regex (regex "(\)|(?<!\.{3}.*)\n)": lookbehind assertion is not fixed length (at offset 15))
    • Invalid regex in grammar: source.matlab (in Matlab.tmbundle/Syntaxes/MATLAB.tmLanguage) contains a malformed regex (regex "(?<=\))|(?>(?<!\.{3}.*)\n)": lookbehind assertion is not fixed length (at offset 22))
    • Invalid regex in grammar: source.matlab (in Matlab.tmbundle/Syntaxes/MATLAB.tmLanguage) contains a malformed regex (regex "(?=;|,|(?<!(?:\.{3}.*))\n|%)": lookbehind assertion is not fixed length (at offset 22))
    • Invalid regex in grammar: source.matlab (in Matlab.tmbundle/Syntaxes/MATLAB.tmLanguage) contains a malformed regex (regex "(\))?[^\S\n]*(?=;|,|(?<!(?:\.{3}...": lookbehind assertion is not fixed length (at offset 35))
    • Invalid regex in grammar: source.matlab (in Matlab.tmbundle/Syntaxes/MATLAB.tmLanguage) contains a malformed regex (regex "(\)|(?<!\.{3}.*)\n)": lookbehind assertion is not fixed length (at offset 15))
    • Invalid regex in grammar: source.matlab (in Matlab.tmbundle/Syntaxes/MATLAB.tmLanguage) contains a malformed regex (regex "(\)|(?<!\.{3}.*)\n)": lookbehind assertion is not fixed length (at offset 15))
    • Invalid regex in grammar: source.matlab (in Matlab.tmbundle/Syntaxes/MATLAB.tmLanguage) contains a malformed regex (regex "(\)|(?<!\.{3}.*)\n)": lookbehind assertion is not fixed length (at offset 15))
  • repository vendor/grammars/Sublime-SQF-Language (from https://github.com/JonBons/Sublime-SQF-Language) (1 errors)

    • Invalid regex in grammar: source.sqf (in SQF.tmLanguage) contains a malformed regex (regex "\b(?i:action|actionids|actionkey...": definition too long (38105 bytes))
  • repository vendor/grammars/TypeScript-TmLanguage (from https://github.com/Microsoft/TypeScript-TmLanguage) (2 errors)

    • Invalid regex in grammar: source.ts (in TypeScript.tmLanguage) contains a malformed regex (regex "(?!(?<![_$[:alnum:]])(?:(?<=\.\....": lookbehind assertion is not fixed length (at offset 731))
    • Invalid regex in grammar: source.tsx (in TypeScriptReact.tmLanguage) contains a malformed regex (regex "(?!(?<![_$[:alnum:]])(?:(?<=\.\....": lookbehind assertion is not fixed length (at offset 731))
  • repository vendor/grammars/apex-tmLanguage (from https://github.com/forcedotcom/apex-tmLanguage.git) (2 errors)

    • Invalid regex in grammar: source.apex (in grammars/apex.tmLanguage) contains a malformed regex (regex "(?=\s(?!\())|(?=\s*$)|(?<=\s*\))": lookbehind assertion is not fixed length (at offset 31))
    • Invalid regex in grammar: source.soql (in grammars/soql.tmLanguage) contains a malformed regex (regex "(?=\s(?!\())|(?=\s*$)|(?<=\s*\))": lookbehind assertion is not fixed length (at offset 31))
  • repository vendor/grammars/atom-language-julia (from https://github.com/JuliaEditorSupport/atom-language-julia) (1 errors)

    • Invalid regex in grammar: source.julia (in grammars/julia.cson) contains a malformed regex (regex "(?<=\S\s+)\b(as)\b(?=\s+\S)": lookbehind assertion is not fixed length (at offset 9))
  • repository vendor/grammars/atom-language-purescript (from https://github.com/purescript-contrib/atom-language-purescript) (1 errors)

    • Invalid regex in grammar: source.purescript (in grammars/purescript.cson) contains a malformed regex (regex "(?<=(\||=)\s*)([\p{Lu}\p{Lt}][\p...": lookbehind assertion is not fixed length (at offset 13))
  • repository vendor/grammars/csharp-tmLanguage (from https://github.com/dotnet/csharp-tmLanguage) (4 errors)

    • Invalid regex in grammar: source.cs (in grammars/csharp.tmLanguage) contains a malformed regex (regex "(?<!\.\s*)\b(await)\b": lookbehind assertion is not fixed length (at offset 9))
    • Invalid regex in grammar: source.cs (in grammars/csharp.tmLanguage) contains a malformed regex (regex "\G(?=(?~\*/)$)": unrecognized character after (? or (?- (at offset 7))
    • Invalid regex in grammar: source.cs (in grammars/csharp.tmLanguage) contains a malformed regex (regex "^(\s*+)(\*(?!/))?(?=(?~\*/)$)": unrecognized character after (? or (?- (at offset 22))
    • Invalid regex in grammar: source.cs (in grammars/csharp.tmLanguage) contains a malformed regex (regex "(?<!\.\s*)\b(await)\b": lookbehind assertion is not fixed length (at offset 9))
  • repository vendor/grammars/gap-tmbundle (from https://github.com/dhowden/gap-tmbundle) (3 errors)

    • Invalid regex in grammar: source.gap (in Syntaxes/GAP.tmLanguage) contains a malformed regex (regex "\b(16Bits_AssocWord|16Bits_Depth...": definition too long (65523 bytes))
    • Invalid regex in grammar: source.gap (in Syntaxes/GAP.tmLanguage) contains a malformed regex (regex "\b(IndicesChiefNormalSteps|Indic...": definition too long (65529 bytes))
    • Invalid regex in grammar: source.gap (in Syntaxes/GAP.tmLanguage) contains a malformed regex (regex "\b(SMTX_GoodElementGModule|SMTX_...": definition too long (42470 bytes))
  • repository vendor/grammars/godot-vscode-plugin (from https://github.com/godotengine/godot-vscode-plugin) (1 errors)

    • Invalid regex in grammar: source.gdscript (in syntaxes/GDScript.tmLanguage.json) contains a malformed regex (regex "(?<!/\s*)(\$\s*|%|\$%\s*)(/\s*)?...": lookbehind assertion is not fixed length (at offset 8))
  • repository vendor/grammars/linter-lilypond (from https://github.com/nwhetsell/linter-lilypond) (1 errors)

    • Invalid regex in grammar: source.lilypond (in grammars/lilypond.cson) contains a malformed regex (regex "(?<!-)\b(!=|\*(?:(?:location|par...": definition too long (35491 bytes))
  • repository vendor/grammars/mathematica-tmbundle (from https://github.com/shadanan/mathematica-tmbundle) (1 errors)

    • Invalid regex in grammar: source.mathematica (in Syntaxes/Mathematica.tmLanguage) contains a malformed regex (regex "(\b|(?<=_))(Abort|AbortKernels|A...": definition too long (54020 bytes))
  • repository vendor/grammars/moonbit-tmLanguage (from https://github.com/moonbitlang/moonbit-tmLanguage.git) (19 errors)

    • Invalid regex in grammar: source.moonbit.config (in grammars/moonbit-config.tmLanguage.json) contains a malformed regex (regex "@[a-zA-Z_\u0080-\uFFFF][a-zA-Z0-...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 10))
    • Invalid regex in grammar: source.moonbit.config (in grammars/moonbit-config.tmLanguage.json) contains a malformed regex (regex "[a-zA-Z_\u0080-\uFFFF][a-zA-Z0-9...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 9))
    • Invalid regex in grammar: source.moonbit.config (in grammars/moonbit-config.tmLanguage.json) contains a malformed regex (regex "[a-zA-Z_\u0080-\uFFFF][a-zA-Z0-9...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 9))
    • Invalid regex in grammar: source.moonbit (in grammars/moonbit.tmLanguage.json) contains a malformed regex (regex "(#?[a-z_\u0080-\uFFFF][a-zA-Z0-9...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 9))
    • Invalid regex in grammar: source.moonbit (in grammars/moonbit.tmLanguage.json) contains a malformed regex (regex "[a-z_\u0080-\uFFFF][a-zA-Z0-9_\u...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 6))
    • Invalid regex in grammar: source.moonbit (in grammars/moonbit.tmLanguage.json) contains a malformed regex (regex "\b(let|const|letrec|type|struct|...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 118))
    • Invalid regex in grammar: source.moonbit (in grammars/moonbit.tmLanguage.json) contains a malformed regex (regex "([a-z_\u0080-\uFFFF][a-zA-Z0-9_\...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 7))
    • Invalid regex in grammar: source.moonbit (in grammars/moonbit.tmLanguage.json) contains a malformed regex (regex "([a-z_\u0080-\uFFFF][a-zA-Z0-9_\...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 7))
    • Invalid regex in grammar: source.moonbit (in grammars/moonbit.tmLanguage.json) contains a malformed regex (regex "([a-z_\u0080-\uFFFF][a-zA-Z0-9_\...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 7))
    • Invalid regex in grammar: source.moonbit (in grammars/moonbit.tmLanguage.json) contains a malformed regex (regex "([a-z_\u0080-\uFFFF][a-zA-Z0-9_\...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 7))
    • Invalid regex in grammar: source.moonbit (in grammars/moonbit.tmLanguage.json) contains a malformed regex (regex "([a-z_\u0080-\uFFFF][a-zA-Z0-9_\...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 7))
    • Invalid regex in grammar: source.moonbit (in grammars/moonbit.tmLanguage.json) contains a malformed regex (regex "(?<=[\w\]\)])(\.)\s*([a-z_\u0080...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 27))
    • Invalid regex in grammar: source.moonbit (in grammars/moonbit.tmLanguage.json) contains a malformed regex (regex "([a-z_\u0080-\uFFFF][a-zA-Z0-9_\...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 7))
    • Invalid regex in grammar: source.moonbit (in grammars/moonbit.tmLanguage.json) contains a malformed regex (regex "(?<=[\w\]\)])(\.)\s*([a-z_\u0080...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 27))
    • Invalid regex in grammar: source.moonbit (in grammars/moonbit.tmLanguage.json) contains a malformed regex (regex "@[a-zA-Z_\u0080-\uFFFF][a-zA-Z0-...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 10))
    • Invalid regex in grammar: source.moonbit (in grammars/moonbit.tmLanguage.json) contains a malformed regex (regex "\b(fn)\s+([a-z_\u0080-\uFFFF][a-...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 16))
    • Invalid regex in grammar: source.moonbit (in grammars/moonbit.tmLanguage.json) contains a malformed regex (regex "([a-z_\u0080-\uFFFF][a-zA-Z0-9_\...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 7))
    • Invalid regex in grammar: source.moonbit (in grammars/moonbit.tmLanguage.json) contains a malformed regex (regex "([a-z_\u0080-\uFFFF][a-zA-Z0-9_\...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 7))
    • Invalid regex in grammar: source.moonbit (in grammars/moonbit.tmLanguage.json) contains a malformed regex (regex "[a-z_\u0080-\uFFFF][a-zA-Z0-9_\u...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 6))
  • repository vendor/grammars/nu-grammar (from https://github.com/hustcer/nu-grammar.git) (1 errors)

    • Invalid regex in grammar: source.nushell (in grammars/tmLanguage.json) contains a malformed regex (regex "(?<=]\s*)(:)\s+(\[)": lookbehind assertion is not fixed length (at offset 8))
  • repository vendor/grammars/objective-c.tmbundle (from https://github.com/textmate/objective-c.tmbundle) (2 errors)

    • Invalid regex in grammar: source.objc.platform (in Syntaxes/Platform.tmLanguage) contains a malformed regex (regex "\b(?:AB(?:AddRecordsError|Multip...": definition too long (32854 bytes))
    • Invalid regex in grammar: source.objc.platform (in Syntaxes/Platform.tmLanguage) contains a malformed regex (regex "\b(?:A(?:M(?:Action(?:A(?:pplica...": definition too long (44404 bytes))
  • repository vendor/grammars/qsharp (from https://github.com/microsoft/qsharp.git) (2 errors)

    • Invalid regex in grammar: source.openqasm (in source/vscode/syntaxes/openqasm.tmLanguage.json) contains a malformed regex (regex "(?<!\s*\.\s*)\b(in|for|return|if...": lookbehind assertion is not fixed length (at offset 12))
    • Invalid regex in grammar: source.openqasm (in source/vscode/syntaxes/openqasm.tmLanguage.json) contains a malformed regex (regex "(?<!\s*\.\s*)\b(OPENQASM|include...": lookbehind assertion is not fixed length (at offset 12))
  • repository vendor/grammars/sprocket-vscode (from https://github.com/stjude-rust-labs/sprocket-vscode.git) (1 errors)

    • Invalid regex in grammar: source.wdl (in syntaxes/wdl.tmGrammar.json) contains a malformed regex (regex "`(?<=^\s*|;\s*|&\s*||\s*|(\s*|``...": lookbehind assertion is not fixed length (at offset 8))
  • repository vendor/grammars/sublime-autoit (from https://github.com/AutoIt/SublimeAutoItScript) (2 errors)

    • Invalid regex in grammar: source.autoit (in AutoIt.tmLanguage) contains a malformed regex (regex "\b(?i:_array1dtohistogram|_array...": definition too long (39591 bytes))
    • Invalid regex in grammar: source.autoit (in AutoIt.tmLanguage) contains a malformed regex (regex "\b(?i:_guictrltoolbar_getbuttoni...": definition too long (39600 bytes))
  • repository vendor/grammars/turtle.tmbundle (from https://github.com/peta/turtle.tmbundle) (5 errors)

    • Invalid regex in grammar: source.turtle (in Syntaxes/Turtle.tmLanguage) contains a malformed regex (regex "\[[\u20\u9\uD\uA]*\]": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 4))
    • Invalid regex in grammar: source.turtle (in Syntaxes/Turtle.tmLanguage) contains a malformed regex (regex "(?x)( (?: [\p{L}\p{M}] | [:0...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 121))
    • Invalid regex in grammar: source.turtle (in Syntaxes/Turtle.tmLanguage) contains a malformed regex (regex "(?x) (?<PN_CHARS_U>[\p{L}\p{M...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 73))
    • Invalid regex in grammar: source.turtle (in Syntaxes/Turtle.tmLanguage) contains a malformed regex (regex "(?x) (?<PNAME_NS> (?: (?: [\...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 68))
    • Invalid regex in grammar: source.turtle (in Syntaxes/Turtle.tmLanguage) contains a malformed regex (regex "(?x)((?<=\s|^|_)(?:[\p{L}\p{M}] ...": PCRE does not support \L, \l, \N{name}, \U, or \u (at offset 57))
  • repository vendor/grammars/vscode-yara (from https://github.com/infosec-intern/vscode-yara.git) (1 errors)

    • Invalid regex in grammar: source.yara (in yara/syntaxes/yara.tmLanguage.json) contains a malformed regex (regex "(?<=(^|[\)]|\b(?:them)\b))(?:\s*...": lookbehind assertion is not fixed length (at offset 25))

Other

The following grammars are not being updated due to problems with the grammars:

  • vendor/grammars/Sublime-QML - skozlovf/Sublime-QML - the project has been restructured and rewritten and only provides a Sublime 3 compatible grammar which is not supported.
  • vendor/grammars/cds-textmate-grammar recently introduced changes that resulted in over 20 unknown property name after \P or \p errors so we've not updated that grammar.
  • vendor/grammars/VscodeAdblockSyntax fails to compile so won't be updated until resolved.
  • vendor/grammars/zenstack - restructured and now doesn't contain a complete grammar file.

Contributor guide