Solidity Grammar Parser
SGP - is a Python package that allows to build an AST for a given Solidity source code.
Kudos
- The original grammar Solidity.g4 was developed and maintained by solidity-parser-antlr.
- The node types system and AST visitor are based on solidity-parser-parser.
Build
Run build.sh that does the following:
- checks if
Pythonis installed and downloads it if not- including
pip - including
antlr4-python3-runtimepackage
- including
- checks if
Javais installed and downloads it if not- including
jre - including
jdk
- including
- checks if
antlr4.jaris downloaded and downloads it if not - runs the ANTLR jar file and compiles the Solidity.g4 file.
The output result can be found in the ./out directory
Tests
Run:
python -m coverage run -m unittest discover -v && python -m coverage reportfor thePythontests- run-tests.sh to execute
antlr4parse testing
License
Metadata
Release files for openzeppelin-solidity-grammar-parser 0.0.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| openzeppelin_solidity_grammar_parser-0.0.5.tar.gz | 67.7 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| openzeppelin_solidity_grammar_parser-0.0.5-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 138.2 kB
Release files / openzeppelin_solidity_grammar_parser-0.0.5.tar.gz
| Download URL | openzeppelin_solidity_grammar_parser-0.0.5.tar.gz |
|---|---|
| Size | 67.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6a81b1af51c42eee3b7502e1d200cd1c94037e948b9895e002f3670694f3f028
|
|
BLAKE2b-256 checksum How to use checksums |
62dbf871319fdadc7aa695416e279ed3951d05eae69f6fcb472a2ddc3f99b7fc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.9.21
|
Release files / openzeppelin_solidity_grammar_parser-0.0.5-py3-none-any.whl
| Download URL | openzeppelin_solidity_grammar_parser-0.0.5-py3-none-any.whl |
|---|---|
| Size | 70.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
00db26614188edb22ee47318dbda115ea6a398de04dc0dbda5de933c6bc19985
|
|
BLAKE2b-256 checksum How to use checksums |
23d28bd10007464f0ed9bb7eb39d1e206fd86322849c643e7b639fbb9b90d442
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.9.21
|