Skip to content

Conversation

@kx0101
Copy link

@kx0101 kx0101 commented Jan 26, 2026

  • normalize filetypes csharp and cs to c_sharp for treesitter (such a pain lol)
  • make sure all treesitter parser and query calls use the normalized language
  • add csharp language support
  • include treesitter queries for csharp methods, singleton methods, and lambdas
  • add tests for the fill_in_function feature with csharp code

@kx0101
Copy link
Author

kx0101 commented Jan 26, 2026

can I join TheStartup now, boss?

@kx0101 kx0101 force-pushed the feat/csharp-support branch from 4a07f70 to ce4a281 Compare January 26, 2026 14:32
@kx0101 kx0101 force-pushed the feat/csharp-support branch 2 times, most recently from caccb73 to 77cc198 Compare January 26, 2026 14:42
--- Mapping table for filetype normalization
--- Keys are raw Neovim filetypes, values are Treesitter-compatible language names
--- @type table<string, _99.treesitter.Lang>
local TS_LANG_MAP = {
Copy link
Owner

Choose a reason for hiding this comment

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

pretty sure i already have this for typescriptreact... but i may have inlined it

@ThePrimeagen
Copy link
Owner

could you figure out where my typescriptreact -> typescript change and combine your c_sharp ft changes?

@ThePrimeagen
Copy link
Owner

@kx0101 make pr_ready

@kx0101
Copy link
Author

kx0101 commented Jan 29, 2026

Hey boss! Of course, I'll check it out later tonight and let you know

@kx0101
Copy link
Author

kx0101 commented Jan 29, 2026

you're totally right! It was on request-context.lua

gonna send a new commit in a sec

@kx0101 kx0101 force-pushed the feat/csharp-support branch from 77cc198 to f8a641b Compare January 29, 2026 21:26
@kx0101
Copy link
Author

kx0101 commented Jan 29, 2026

fyi: For some weird reason I'm facing this error when doing make pr_ready but I didn't change anything in that file 😄

echo "===> Checking format"
===> Checking format
stylua lua/ --config-path=.stylua.toml --check
error: could not format file lua/99/editor/treesitter.lua: error parsing:
 - unexpected token `end_of_loops` (78:16 to 78:28), unexpected expression when looking for a statement
 - unexpected token `end_of_loops` (78:16 to 78:28), expected `end` to conclude `if`
 - unexpected token `end` (79:9 to 79:12), unexpected expression when looking for a statement
 - unexpected token `::` (83:3 to 83:5), unexpected token, this needs to be a statement
 - unexpected token `::` (83:17 to 83:19), unexpected expression when looking for a statement
 - unexpected token `::` (83:17 to 83:19), unexpected token, this needs to be a statement
make: *** [Makefile:7: lua_fmt_check] Error 2
➜  99 git:(feat/csharp-support) stylua --version
stylua 2.3.1

so I decided to push in case it's just me that has this issue

@kx0101 kx0101 force-pushed the feat/csharp-support branch from f8a641b to 7aa804a Compare January 29, 2026 21:28
file_type = "typescript"
end

if file_type == "csharp" or file_type == "cs" then
Copy link
Owner

Choose a reason for hiding this comment

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

probably should create a map, but we will do it for the next time (rule of 3)

@ThePrimeagen
Copy link
Owner

fix ci pls

execute make pr_ready until you make sweet fixes :)

likely just a make lua_fmt

@kx0101
Copy link
Author

kx0101 commented Jan 30, 2026

@ThePrimeagen still doesn't work :/

➜  99 git:(feat/csharp-support) make lua_fmt
echo "===> Formatting"
===> Formatting
stylua lua/ --config-path=.stylua.toml
error: could not format file lua/99/editor/treesitter.lua: error parsing:
 - unexpected token `end_of_loops` (78:16 to 78:28), unexpected expression when looking for a statement
 - unexpected token `end_of_loops` (78:16 to 78:28), expected `end` to conclude `if`
 - unexpected token `end` (79:9 to 79:12), unexpected expression when looking for a statement
 - unexpected token `::` (83:3 to 83:5), unexpected token, this needs to be a statement
 - unexpected token `::` (83:17 to 83:19), unexpected expression when looking for a statement
 - unexpected token `::` (83:17 to 83:19), unexpected token, this needs to be a statement
make: *** [Makefile:3: lua_fmt] Error 2

@ThePrimeagen
Copy link
Owner

hmmmmmm, let me look at this

@kx0101
Copy link
Author

kx0101 commented Jan 30, 2026

it's weird because the error in github ci's is different than the one i'm getting too 😄

it's the same error you saw on stream today

@kx0101 kx0101 force-pushed the feat/csharp-support branch from 7aa804a to 8e180c3 Compare January 30, 2026 23:36
local found = Agents.by_name(rules, prompt)

eq({ "front-end" }, found.names)
eq({"front-end"}, found.names)
Copy link
Author

Choose a reason for hiding this comment

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

@ThePrimeagen I think now it will work just fine

@ThePrimeagen
Copy link
Owner

I'll have to merge and fix on Monday, it's not a big deal

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.

2 participants