Skip to main content

A Calcium language interpreter

Project description

calciumpy

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. Calcium is primarily designed as a subset of Python.

How to create the interpreter and run code

from calciumpy.runtime import Runtime

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

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

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

calciumpy-0.2.0.tar.gz (12.9 kB view details)

Uploaded Source

Built Distribution

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

calciumpy-0.2.0-py3-none-any.whl (21.8 kB view details)

Uploaded Python 3

File details

Details for the file calciumpy-0.2.0.tar.gz.

File metadata

  • Download URL: calciumpy-0.2.0.tar.gz
  • Upload date:
  • Size: 12.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for calciumpy-0.2.0.tar.gz
Algorithm Hash digest
SHA256 92d7e0cd22e40aada59bb8185fbe91f865d7012044fd40a56c8f738a959917ac
MD5 ea97cf1d9eb0de24ef7e30c391a63589
BLAKE2b-256 ae3aec01f2411099b250f313a3b5655f53ecc895533ba9a9c277c0d34f6b8f75

See more details on using hashes here.

File details

Details for the file calciumpy-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: calciumpy-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 21.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for calciumpy-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 955eeb4d786ad59f2a44a68f9f0b8edeb808b6e652df03bb9fcdd537922b0ced
MD5 5d081f04ace91effd36d45808a859a50
BLAKE2b-256 5419a08e82b57b36292c626ad839f85bd9ab75ae022143615d2dc0ca6f9edb48

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