Solidity ANTLR4 grammar Python parser
Project description
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
Python
is installed and downloads it if not- including
pip
- including
antlr4-python3-runtime
package
- including
- checks if
Java
is installed and downloads it if not- including
jre
- including
jdk
- including
- checks if
antlr4.jar
is 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 report
for thePython
tests- run-tests.sh to execute
antlr4
parse testing
License
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for openzeppelin-solidity-grammar-parser-0.0.3.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1db2d507ea5f884d506e76514fcdfca51b87463b9c64e842b7a83cd49d801f87 |
|
MD5 | ba1ac396f997b8799146dc08e6004a34 |
|
BLAKE2b-256 | d00acfdaf9552dc65f9e5fb45cdc61dc4f42780d22091384ecb8d1b5be101d23 |
Close
Hashes for openzeppelin_solidity_grammar_parser-0.0.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5f5a4e73a2e3e074b972c862b40dc2587645f5bcc8e80f25d629c794bfdc4530 |
|
MD5 | a56aac3c6b19c99b7e1b8c470fda1d2b |
|
BLAKE2b-256 | 96685cbf129df5820963e6edc607085a272deba87d90091a542788270bbc15a2 |