Metadata-Version: 2.4
Name: mirascript
Version: 0.1.82
Classifier: Development Status :: 4 - Beta
Classifier: Programming Language :: Rust
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: Free Threading
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Classifier: Programming Language :: Python :: 3.15
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Programming Language :: Python :: Implementation :: PyPy
Classifier: Topic :: Software Development :: Compilers
Classifier: Topic :: Software Development :: Interpreters
Classifier: Typing :: Typed
Requires-Dist: typing-extensions>=4.7.1
Requires-Dist: astunparse>=1.6.3 ; python_full_version < '3.9'
Summary: MiraScript 是 CloudPSS 维护的表达式优先脚本语言项目。Python 绑定用于在 Python 中调用 MiraScript 编译器能力，支持脚本编译与执行。
Keywords: mirascript,language,compiler,runtime,vm
Author-email: CloudPSS <zhangdaming@cloudpss.net>
License-Expression: MIT
Requires-Python: >=3.7
Description-Content-Type: text/markdown; charset=UTF-8; variant=GFM
Project-URL: Documentation, https://mira.cloudpss.net/
Project-URL: Repository, https://github.com/CloudPSS/MiraScript

# MiraScript

MiraScript 是 CloudPSS 维护的表达式优先脚本语言项目。Python 绑定用于在 Python 中调用 MiraScript 编译器能力，支持脚本编译与执行。

## 安装

```bash
pip install mirascript
```

## 快速开始

命令行执行：

```bash
mirascript -v x=1.3 -e "sin(x) + cos(PI - x)"
```

在 Python 代码中执行：

```python
from mirascript import compile

script, diagnostics = compile("sin(x) + cos(PI - x)")
result = script({"x": 1.3})
```

## 本地开发

初始化环境：

```bash
uv sync
uv run poe init
```

运行测试与检查：

```bash
uv run poe test
uv run poe check
```

格式化代码：

```bash
uv run poe format
```

调试入口（生成 `debug_output.py`）：

```bash
uv run poe debug
```

