Skip to main content

Solidity grammar for tree-sitter

Project description

🌴 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!

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

tree_sitter_solidity-1.2.12.tar.gz (156.6 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

tree_sitter_solidity-1.2.12-cp38-abi3-win_arm64.whl (61.0 kB view details)

Uploaded CPython 3.8+Windows ARM64

tree_sitter_solidity-1.2.12-cp38-abi3-win_amd64.whl (69.0 kB view details)

Uploaded CPython 3.8+Windows x86-64

tree_sitter_solidity-1.2.12-cp38-abi3-musllinux_1_2_x86_64.whl (90.9 kB view details)

Uploaded CPython 3.8+musllinux: musl 1.2+ x86-64

tree_sitter_solidity-1.2.12-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (93.8 kB view details)

Uploaded CPython 3.8+manylinux: glibc 2.17+ ARM64

tree_sitter_solidity-1.2.12-cp38-abi3-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (91.8 kB view details)

Uploaded CPython 3.8+manylinux: glibc 2.17+ x86-64manylinux: glibc 2.5+ x86-64

tree_sitter_solidity-1.2.12-cp38-abi3-macosx_11_0_arm64.whl (61.8 kB view details)

Uploaded CPython 3.8+macOS 11.0+ ARM64

tree_sitter_solidity-1.2.12-cp38-abi3-macosx_10_9_x86_64.whl (59.0 kB view details)

Uploaded CPython 3.8+macOS 10.9+ x86-64

File details

Details for the file tree_sitter_solidity-1.2.12.tar.gz.

File metadata

  • Download URL: tree_sitter_solidity-1.2.12.tar.gz
  • Upload date:
  • Size: 156.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for tree_sitter_solidity-1.2.12.tar.gz
Algorithm Hash digest
SHA256 53b6c5cdd3b80d3f9afc06715e81b6c213a791d329ac3548b568e226e25bdb60
MD5 1ed703fb4a13b8699ca169d9abb672a3
BLAKE2b-256 8403f872251876560845f2fd8996cea56041f6548ab3f767241ba2a7c169b343

See more details on using hashes here.

File details

Details for the file tree_sitter_solidity-1.2.12-cp38-abi3-win_arm64.whl.

File metadata

File hashes

Hashes for tree_sitter_solidity-1.2.12-cp38-abi3-win_arm64.whl
Algorithm Hash digest
SHA256 7785529965a3cada2a90090f2076d66cea5c9ce3db156eba3d34f6d9be0e73b3
MD5 81f24534e9cbb768a98d405cc45c43a2
BLAKE2b-256 1aa1f24377c4a6b1b99cf71ddbe26066b7898dab167389289d9cf190c95d8d2b

See more details on using hashes here.

File details

Details for the file tree_sitter_solidity-1.2.12-cp38-abi3-win_amd64.whl.

File metadata

File hashes

Hashes for tree_sitter_solidity-1.2.12-cp38-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 9db4bb10cb0e9d8c3178372c9105b0e1b3f1803426517af5e0142a978885e190
MD5 7e9e7beeb71e41a1c2fd5995c6b891ac
BLAKE2b-256 67e1c6048d60c9ae47bec928c7184f2c82e5f271a8c75bd54ab77d8f682ac010

See more details on using hashes here.

File details

Details for the file tree_sitter_solidity-1.2.12-cp38-abi3-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for tree_sitter_solidity-1.2.12-cp38-abi3-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 a30dc09653366f320cd5ed6f469ffda14f1daf2aa8c6da0be6355a79fbd6f23b
MD5 c5d0ac8aa4b941846f110ee56ee41501
BLAKE2b-256 334c6de4246a0085667e6e4ee559c16043eb658fe4f7c83d94eb72d25236a9e8

See more details on using hashes here.

File details

Details for the file tree_sitter_solidity-1.2.12-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for tree_sitter_solidity-1.2.12-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 72c5a7d1b61ecc6346afb9eaad18f24c99ed8a9e069fde6a384a2738121f95b0
MD5 8ef654cc69ec4f3865dfd559d5e5104e
BLAKE2b-256 db87adb823c4c5277e66b3276cca52407886eb4694a3cc106617de04018226ac

See more details on using hashes here.

File details

Details for the file tree_sitter_solidity-1.2.12-cp38-abi3-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for tree_sitter_solidity-1.2.12-cp38-abi3-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 a0adafc083ca50184d5235a1ec018d3d6cd43d95a8c17cc372010b5f0d1e43eb
MD5 6ee016a7edd12e67de8e6c0074c404e1
BLAKE2b-256 e5b120b07d1cc5469ed1036c1e628ff8687c2e4b7c6eb69f93144f5827d54538

See more details on using hashes here.

File details

Details for the file tree_sitter_solidity-1.2.12-cp38-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for tree_sitter_solidity-1.2.12-cp38-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 96da0debd700fc2ea25bcadc9f8ca39cdd238685e1d459ab2cfd37b967581ddd
MD5 b04319946ff8830dc533af2ce4fc99c1
BLAKE2b-256 678cfea7ca6fcc14c2d17e53fa047b3d196505ed7fdcc43323758236c227b13e

See more details on using hashes here.

File details

Details for the file tree_sitter_solidity-1.2.12-cp38-abi3-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for tree_sitter_solidity-1.2.12-cp38-abi3-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 857352bf16d88c9f565353ea9ebebc0a695a1d57673e470df26726f422c9879f
MD5 bb8748a6468f0d91b141657e98470f5c
BLAKE2b-256 aee56df5794ce99d4035e6bf8f09e87de653a889746ddc594a873b9ea095ea78

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page