Skip to main content

A better Python superset language.

Project description

MíngShé

A better Python superset language. Use Pegen to compile the code.

“鲜山多金玉,无草木,鲜水出焉,而北流注于伊水。其中多鸣蛇,其状如蛇而四翼,其音如磬,见则其邑大旱”——《山海经》

Install

pip install mingshe

Usage

As a script

Write the following code to hello.she, and then run mingshe ./hello.she.

"hello world" |> print

As a module

Just like use a python module, you can use a mingshe module.

# lib.she
def digit_sum(s: str) -> int:
    return s |> map(int, ?) |> sum
# main.py
from lib import digit_sum

print(digit_sum('123456'))

Compile to python

Use mingshe --compile ... to compile to Python code, and it can be compiled to the specified Python version: mingshe --compile --python 2.7 ....

Change log

Read releases to see the change log.

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

mingshe-0.8.2.tar.gz (71.1 kB view hashes)

Uploaded Source

Built Distribution

mingshe-0.8.2-py3-none-any.whl (67.2 kB view hashes)

Uploaded Python 3

Supported by

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