Metadata-Version: 2.4
Name: calciumlang
Version: 0.0.4
Summary: A Calcium language interpreter
Project-URL: Homepage, https://github.com/0xCAF2/calcium-py
Author-email: 0xCAF2 <roki@0xcaf2.dev>
License-File: LICENSE
Keywords: calcium,interpreter,json
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Requires-Python: >=3.9
Description-Content-Type: text/markdown

# calcium-py

A Calcium language intepreter on Python

## What is Calcium language?

Calcium is a programming language that takes a JSON array as input. It is interoperable with the Python language, allowing you to utilize Python's standard libraries and more. It is primarily designed as a subset of Python.

## How to create the interpreter and run Calcium code

```python
from calciumlang.runtime import Runtime

# Calcium code is given as a JSON array.
calcium_code = [
  [1, [], "#", "0.0.4"],
  [1, [], "expr", ["call", ["var", "print"], ["Hello, World."]]],
  [1, [], "end"],
]

# The Runtime executes Calcium code.
r = Runtime(calcium_code)
r.run()  # outputs 'Hello, World.'
```

## Applications using Calcium

With Blockly, [you can generate Calcium code in the visual environment](https://capg.app/). This editor produces Calcium code (a JSON array) that can be executed by the calcium-py runtime.
