Skip to content

Add x86 assembly grammar#129

Merged
danipen merged 3 commits into
danipen:masterfrom
RysteQ:master
May 26, 2026
Merged

Add x86 assembly grammar#129
danipen merged 3 commits into
danipen:masterfrom
RysteQ:master

Conversation

@RysteQ

@RysteQ RysteQ commented May 26, 2026

Copy link
Copy Markdown
Contributor

Added x86 grammar support based on the following work by kapitche .

The tests are all passing on my side and I did run the demo on some sample code and it looks like it is working. If I missed anything, especially inside the cgmanifest.json file, please do tell me.

@danipen danipen merged commit c68ac08 into danipen:master May 26, 2026
5 checks passed
@danipen danipen requested a review from Copilot May 26, 2026 09:34

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new embedded TextMate grammar package for x86 assembly so RegistryOptions can expose and load source.x86asm (and associated language configuration) alongside the existing bundled grammars.

Changes:

  • Added a new x86asm grammar package (tmLanguage, VS Code-style package metadata, language configuration, and cgmanifest registration).
  • Registered the new grammar in GrammarNames so it’s discoverable by RegistryOptions.
  • Updated the grammar availability test to reflect the additional language.

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
src/TextMateSharp.Grammars/Resources/Grammars/x86asm/syntaxes/x86asm.tmLanguage.json New TextMate grammar rules for x86 assembly tokenization/scoping.
src/TextMateSharp.Grammars/Resources/Grammars/x86asm/package.nls.json Localized display name/description strings for the grammar package.
src/TextMateSharp.Grammars/Resources/Grammars/x86asm/package.json Package definition that registers the language + grammar scope mapping.
src/TextMateSharp.Grammars/Resources/Grammars/x86asm/language-configuration.json Comment/bracket/auto-closing configuration for the language.
src/TextMateSharp.Grammars/Resources/Grammars/x86asm/cgmanifest.json Component governance metadata for the upstream-derived grammar content.
src/TextMateSharp.Grammars/GrammarNames.cs Adds the new grammar package to the supported list.
src/TextMateSharp.Grammars.Tests/GrammarTests.cs Updates expected available-language count after adding the grammar.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +162 to +168
"name": "keyword.control.section.x86asm",
"match": "\\.(section .(text|data|bss|tbss|tcomm))\\b"
},
{
"name": "keyword.control.section.x86asm",
"match": "\\.(text|data|bss|tbss|tcomm|rodata)\\b"
}
Comment on lines +2 to +4
"$schema": "https://raw.githubusercontent.com/martinring/tmlanguage/master/tmlanguage.json",
"name": "x86/x64/ARM Assembly",
"patterns": [
Comment thread src/TextMateSharp.Grammars/GrammarNames.cs
fuzzzerd pushed a commit to fuzzzerd/SharpFM that referenced this pull request Jun 30, 2026
Updated
[TextMateSharp.Grammars](https://github.com/danipen/TextMateSharp) from
2.0.3 to 2.0.4.

<details>
<summary>Release notes</summary>

_Sourced from [TextMateSharp.Grammars's
releases](https://github.com/danipen/TextMateSharp/releases)._

## 2.0.4

## What's Changed
* Fix AttributedScopeStack equality type check by @​Copilot in
danipen/TextMateSharp#111
* Fix multiple race conditions in TMModel #​109 by @​udlose in
danipen/TextMateSharp#114
* Performance/reduce allocations, increase test coverage, configure code
coverage, fix race condition by @​udlose in
danipen/TextMateSharp#115
* Fix #​116 and Performance/reduce allocations by @​udlose in
danipen/TextMateSharp#121
* [Breaking]: Fixes #​117 - Fix typo: rename PushAtributed to
PushAttributed by @​udlose in
danipen/TextMateSharp#122
* [Breaking]: Part 1 of 2 Restrict visibility, add immutability,
refactor internals… by @​udlose in
danipen/TextMateSharp#124
* Part 2 of 3 for #​123 - Fix sealed & visibility issues part2 by
@​udlose in danipen/TextMateSharp#125
* Update onigwrap to 1.0.11 by @​pauldumais in
danipen/TextMateSharp#127
* Add x86 assembly grammar by @​RysteQ in
danipen/TextMateSharp#129
* Update CI workflows to use .NET 8 SDK by @​danipen in
danipen/TextMateSharp#130

## New Contributors
* @​Copilot made their first contribution in
danipen/TextMateSharp#111
* @​udlose made their first contribution in
danipen/TextMateSharp#114
* @​pauldumais made their first contribution in
danipen/TextMateSharp#127
* @​RysteQ made their first contribution in
danipen/TextMateSharp#129

**Full Changelog**:
danipen/TextMateSharp@v2.0.3...v2.0.4

Commits viewable in [compare
view](danipen/TextMateSharp@v2.0.3...v2.0.4).
</details>

[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=TextMateSharp.Grammars&package-manager=nuget&previous-version=2.0.3&new-version=2.0.4)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants