tree-sitter-langs icon indicating copy to clipboard operation
tree-sitter-langs copied to clipboard

Add solidity grammar and highlighting

Open YongJieYongJie opened this issue 2 years ago • 4 comments

Hi, thank for working on the tree-sitter related-modules for Emacs, I've added the following for Solidity:

  • grammar
  • highlighting
  • association with the major mode solidity-mode
  • updated CHANGELOG.md

Do have a look when you have time, and let me know if any change is required :pray:

The highlighting looks something like the following: image

YongJieYongJie avatar Mar 12 '22 08:03 YongJieYongJie

@YongJieYongJie I have no relation with this repo, but thanks for putting in this effort.

Could you tell me how you got this to work?

I was trying to do something similar and ran into your PR. However, even after compiling the .so file with cargo I'm getting an error when trying to use it in Emacs.

tree-sitter-load: Language load failed: ".../tree-sitter-langs/bin/solidity.so: undefined symbol: tree_sitter_solidity"

Malabarba avatar May 24 '22 15:05 Malabarba

@Malabarba It might have something to do with case-sensitivity, the s of solidity in particular.

See this issue fro neovim: https://github.com/nvim-treesitter/nvim-treesitter/issues/1168#issuecomment-871546426

This section in particular: image

In any case, is there a repo / PR for what you are working on? It will be more appropriate to discuss there.

YongJieYongJie avatar May 24 '22 19:05 YongJieYongJie

Hi @ubolonton, I think there might be an issue with the Windows CI:

https://github.com/emacs-tree-sitter/tree-sitter-langs/runs/5721203577?check_suite_focus=true image

Let me know if there's anything I can do to help fix it :+1:

YongJieYongJie avatar May 24 '22 19:05 YongJieYongJie

In any case, is there a repo / PR for what you are working on? It will be more appropriate to discuss there.

No, I just cloned your fork. But I can pull up an issue there for us to discuss.

Malabarba avatar May 26 '22 15:05 Malabarba