Skip to content
프로젝트

소개

A python-ish pure and total functional programming language

프로그래밍 언어 및 런타임

이 수치를 측정하는 방법

측정된 스타 증가

in 24h
0
in 7 days
0
in 15 days
0
in 1 month
기록 수집 중

서로 겹치는 기간의 순증가량이며 일별 합계가 아닙니다. 측정값이 없으면 비워 둡니다. 스타는 관심도를 나타내며 품질을 보장하지 않습니다.

README.md

Original

The Bosatsu Programming Language

Codecov

Bosatsu (菩薩) is the transliteration in Japanese of the sanskrit bodhisattva. A bodhisattva is someone who can reach enlightenment but decides not to, to help others achieve that goal. -- Wikipedia

Bosatsu is a simple, non-turing complete language designed for configuration, queries and scripting. It borrows from Python, Haskell, Dhall and Rust.

Bosatsu aims to keep logic flow literal in the source even when the compiler is doing sophisticated checking. A reader should be able to see the package interface at the top of the file, where each non-predef name comes from, and how control flows through the program directly from the syntax. Bosatsu is stricter about names than about type annotations: dependencies stay explicit, while most types can be inferred unless the source literally names a foreign type.

Correctness comes from a sound total language with explicit effects and private-by-default package boundaries. Simplicity comes from local reasoning, not from minimizing keystrokes at all costs.

Please see the documentation site and the Getting started guide or try basic expressions using this in-browser Bosatsu compiler.

An example of Bosatsu

Here is a working Bosatsu program to solve the first Project Euler problem:

package Euler/One

# see:
# https://projecteuler.net/problem=1
# Find the sum of all the multiples of 3 or 5 below 1000.

operator == = eq_Int
operator % = mod_Int

def operator ||(x, y):
  True if x else y

def keep(i):
  (i % 3 == 0) || (i % 5 == 0)

def sum(as): as.foldl_List(0, add)

# here is the python version:
# >>> sum(i for i in xrange(1000) if keep_fn(i))
# 233168
#
# bosatsu version here
computed = sum([i for i in range(1000) if keep(i)])

test = Assertion(computed == 233168, "expected 233168")

Contributing

Please feel free to file an issue to discuss making a change to Bosatsu or to ask a question about how Bosatsu might be useful for a use-case that is interesting to you.

Tree-sitter + Neovim

Bosatsu has an in-repo Tree-sitter grammar at syntax/tree-sitter-bosatsu.

For local parser workflows and Neovim setup (:TSInstall bosatsu, :TSUpdate bosatsu), see: syntax/tree-sitter-bosatsu/README.md.

Release

See release.md for the release workflow and tagging steps.

MergeXO container setup

.mergexo.toml holds repository-owned policy and selects scripts/container_setup.sh. MergeXO captures that standalone script before checkout and runs it as root inside each disposable worker container. Do not run it on your workstation. The setup installs the CI JDK (Temurin 17); downloaded tool archives are version- and checksum-pinned.

The service still owns the worker backend, credentials and permissions. Enabling containers requires a service configuration change and restart; later repo policy or setup changes are picked up for newly captured work. A host-native service rejects setup-bearing overlays and retains its startup baseline.

The required test command remains scripts/test_basic.sh. The setup also installs the sbt launcher; the project selects its sbt version in project/build.properties.

관련 프로젝트 살펴보기

불러오는 중…