Skip to main content

A minimal python parser, written in python

Project description

MiniPyParser

A minimal python parser, written in python

Upload Python Package

View License

Installing

Local

$ pip install -e minipyparser

PyPI

$ pip install minipyparser

Using

# examples/hello_world.py

print("hello, from mars!")
# examples/main.py

from minipyparser import tokenizer
from minipyparser import parser

for ast in parser.parse(tokenizer.tokenize(open("hello_world.py"))):
    print(ast)
$ cd examples
$ python main.py

Comment(value='examples/hello_world.py')
Call(head=Name(print), args=[Literal(value='hello, from mars!')])

2022 - Marcel Guinhos

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

minipyparser-0.1.0.tar.gz (6.2 kB view details)

Uploaded Source

Built Distribution

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

minipyparser-0.1.0-py3-none-any.whl (6.8 kB view details)

Uploaded Python 3

File details

Details for the file minipyparser-0.1.0.tar.gz.

File metadata

  • Download URL: minipyparser-0.1.0.tar.gz
  • Upload date:
  • Size: 6.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.9.13

File hashes

Hashes for minipyparser-0.1.0.tar.gz
Algorithm Hash digest
SHA256 e840a853a519ec4c269f73ab74611ed8cd863e1a17ad88477698f5a84ea114f2
MD5 741f2ae519ccd07fc9aa9cff5e79c013
BLAKE2b-256 573b6f2f6eb0aa1216e51b50de14652b19a76988949ae88e067f3ed5f2a53d31

See more details on using hashes here.

File details

Details for the file minipyparser-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: minipyparser-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 6.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.9.13

File hashes

Hashes for minipyparser-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 d5f8f54998f0166aaa57199fb0bb444b4d239aabd3fd5f0bc269eca6cce12c59
MD5 5ec28ff25c1e3798abbcd8874478fb94
BLAKE2b-256 d6dabe89c9b503fd96199ecf3ac5b176b3f9c7048f0f043931c44c510de27d7a

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