This is the source code repository for MoonBit, a programming language that is user-friendly, builds fast, and produces high quality output.
Building a programming language is a long journey. It took Rust 9 years and Go 5 years to reach 1.0. Made by a young and driven team, MoonBit is steadily moving forward. We understand that community adoption and expansion are key to a new language, and we’re fully committed to nurturing an engaged and collaborative community around MoonBit. So far, we have open-sourced the core library and most tools, including build tools, lex, markdown, and more to come. Having the compiler source available is important for security measures. Open-sourcing the Wasm backend is another major step, and it is on our roadmap to open source more (moonfmt, moondoc) in the future.
- OCaml 4.14.2
- OPAM
Build with following scripts:
opam switch create 4.14.2
opam install -y dune
dune build -p moonbit-lang
The project is evolving extremely fast that it is not yet ready for massive community contributions.
If you do have interest in contributing, thank you!
Please sign the CLA first. For small bug fixes, you are welcome to send the patch to our email. For large contributions, it is recommended to open a discussion first in our community forum.
MoonBit adopts MoonBit Public License which is a relaxed SSPL (Server Side Public License) with two key exceptions:
- Artifacts produced by the MoonBit compiler may be licensed by the user under any license of their choosing, users have the freedom to choose the license for their own MoonBit source code and generated artifacts.
- Modifications to the compiler are allowed for non-commercial purposes.
While we value openness, we chose the relaxed SSPL instead of a fully permissive license for two main reasons:
- MoonBit is still in its beta-preview stage. Introducing forks at this point could risk destabilizing the project. We aim to reach a more mature and stable status before welcoming community contributions.
- We want to safeguard against large cloud vendors leveraging our work for commercial purposes in a way that could undermine our efforts.
In the past two years, our team worked hard to improve MoonBit and its toolchain, staying true to our vision of creating a fast, simple, and efficient language. By open sourcing MoonBit, we would like to reassure our users that our team remains dedicated to MoonBit's pace of growth and innovation. We also want to ensure our users that MoonBit is not going to adopt open-core model, all MoonBit users will get the best developed compiler and IDE support. MoonBit team will try to generate revenue through cloud hosting services and hardware SDKs in the longer term.
We are grateful for the support of the community. Special thanks to Jane Street for their excellent PPX libraries, this repo has used some of their PPX functions.