difftastic/vendored_parsers/tree-sitter-solidity
Valentin b86d4dbf9e Add solidity support 2023-04-05 11:12:19 +07:00
..
.github/workflows Add 'vendored_parsers/tree-sitter-solidity/' from commit '168020304759ad5d8b4a88a541a699134e3730c5' 2023-04-04 16:59:26 +07:00
.vscode Add 'vendored_parsers/tree-sitter-solidity/' from commit '168020304759ad5d8b4a88a541a699134e3730c5' 2023-04-04 16:59:26 +07:00
bindings Add 'vendored_parsers/tree-sitter-solidity/' from commit '168020304759ad5d8b4a88a541a699134e3730c5' 2023-04-04 16:59:26 +07:00
queries Add 'vendored_parsers/tree-sitter-solidity/' from commit '168020304759ad5d8b4a88a541a699134e3730c5' 2023-04-04 16:59:26 +07:00
src Add solidity support 2023-04-05 11:12:19 +07:00
test Add 'vendored_parsers/tree-sitter-solidity/' from commit '168020304759ad5d8b4a88a541a699134e3730c5' 2023-04-04 16:59:26 +07:00
typed-libraries/python Add 'vendored_parsers/tree-sitter-solidity/' from commit '168020304759ad5d8b4a88a541a699134e3730c5' 2023-04-04 16:59:26 +07:00
.gitignore Add 'vendored_parsers/tree-sitter-solidity/' from commit '168020304759ad5d8b4a88a541a699134e3730c5' 2023-04-04 16:59:26 +07:00
.npmignore Add 'vendored_parsers/tree-sitter-solidity/' from commit '168020304759ad5d8b4a88a541a699134e3730c5' 2023-04-04 16:59:26 +07:00
Cargo.toml Add 'vendored_parsers/tree-sitter-solidity/' from commit '168020304759ad5d8b4a88a541a699134e3730c5' 2023-04-04 16:59:26 +07:00
LICENSE Add 'vendored_parsers/tree-sitter-solidity/' from commit '168020304759ad5d8b4a88a541a699134e3730c5' 2023-04-04 16:59:26 +07:00
README.md Add 'vendored_parsers/tree-sitter-solidity/' from commit '168020304759ad5d8b4a88a541a699134e3730c5' 2023-04-04 16:59:26 +07:00
binding.gyp Add 'vendored_parsers/tree-sitter-solidity/' from commit '168020304759ad5d8b4a88a541a699134e3730c5' 2023-04-04 16:59:26 +07:00
grammar.js Add 'vendored_parsers/tree-sitter-solidity/' from commit '168020304759ad5d8b4a88a541a699134e3730c5' 2023-04-04 16:59:26 +07:00
package-lock.json Add 'vendored_parsers/tree-sitter-solidity/' from commit '168020304759ad5d8b4a88a541a699134e3730c5' 2023-04-04 16:59:26 +07:00
package.json Add 'vendored_parsers/tree-sitter-solidity/' from commit '168020304759ad5d8b4a88a541a699134e3730c5' 2023-04-04 16:59:26 +07:00
sample-file.sol Add 'vendored_parsers/tree-sitter-solidity/' from commit '168020304759ad5d8b4a88a541a699134e3730c5' 2023-04-04 16:59:26 +07:00

README.md

🌴 tree-sitter-solidity

Node.js CI npm version

💡 this grammar is still in development, the structure of the generated AST is not stable

This repository contains a grammar for tree-sitter.

The goal of this project is to provide an parser efficient low-dependency parser for solidity which targets most solidity versions in use and is designed for enabling metaprogramming.

Navigating this repository

The primary file in this repository is grammar.js which describes the tree-sitter grammar.

# Primary file:
grammar.js
# Tests:
/test/**/*

# Auto generated:
/src/**/*
index.js
binding.gyp

References

-> Ethereum solidity grammar:

-> Tree-sitter javascript grammar: https://github.com/tree-sitter/tree-sitter-javascript/blob/master/grammar.js

-> Solidity antlr grammar: https://github.com/ConsenSys/solidity-parser-antlr

Major inspriration & some structures have been taken from tree-sitter-javascript, a big thanks to the contributors to this repo!