https://bitopia.io https://bitopia.io

mizusato e8fe39696f fix list-based string formatting il y a 5 ans
build fbb5eb1ac3 change directory structure il y a 5 ans
parser c8c895cd9b fix and add test for finally {} il y a 5 ans
runtime e8fe39696f fix list-based string formatting il y a 5 ans
test 638bd8ff92 add deg2rad() and rad2deg() il y a 5 ans
transpiler 17add12c98 update comments il y a 5 ans
.eslintrc.json 327ce0bffc fix eslintrc il y a 5 ans
.gitignore fbb5eb1ac3 change directory structure il y a 5 ans
COPYING c54dc9a449 add license il y a 5 ans
Makefile c02aab0914 avoid hard-coded constants il y a 5 ans
README.md b351074523 fix typo il y a 5 ans
bundle.py c02aab0914 avoid hard-coded constants il y a 5 ans
load.html c87296f5da async unit test il y a 5 ans
main.go 5caf1d677a enhance main() il y a 5 ans
repl.js 143da82fb5 more clear parser error il y a 5 ans
run.js 1acccdaf9c add source file executor il y a 5 ans
test.js 581f04c7c0 separate std wrapper and containers, add set il y a 5 ans

README.md

熊語言・KumaChan Programming Language

KumaChan (ja. くまちゃん) is an experimental programming language, and is still under development.

Yet Another Programming Language?

I have been using JavaScript for several years and can't tolerate the BAD DESIGN of it anymore, so I created a new language.

However, the new language does NOT intend to be a substitution of JavaScript. It's designed for GUI (aka. client-side) programming only, and does NOT intend to be used on server-side. Its design focuses more on abstraction ability rather than performance.

For more details, see documentation.

Development Progress

This repository contains a parser which defines the syntax of KumaChan, and a transpiler which is capable to transpile KumaChan code into JavaScript, along with a necessary runtime library.

The current implementation of runtime (based on JavaScript) is created for DEMO Purpose and is extraordinarily naive. I don't want to maintain it, and is going to reimplement the whole runtime using Golang. Finally, all JavaScript code in this repository will be wiped. I want the Golang implementation to be the official implementation.

Rewriting the runtime using Golang may cause difficulty when developing Web applications, because WebAssembly is not widely supported in browsers, meanwhile the binary file of Golang program is very large. (although it does not matter when developing off-line apps using Electron.)

But using JavaScript implementation of the runtime in production also requires a rewrite of the current code, because the current implementation is too naive to be used in production, and is not integrated with Webpack ecosystem.

Currently I am working on the rewriting of runtime. After I finished the new runtime, I am going to integrate GTK2 with it using go-gtk to enable desktop GUI programming for this language. I hope it can start the age of declarative programming for native desktop GUI.

Usage

Build

Make sure you have make, bash, golang, python3 and nodejs installed on your system before building.

$ git clone https://notabug.org/mizusato/KumaChan
$ cd KumaChan
$ make

Run the REPL

$ ./repl.js

Run a script file

Note: shebang is NOT supported currently.

$ cat << EOF > /tmp/test.k
module main
print('Change The World')
EOF
$ ./run.js /tmp/test.k

Syntax Highlighting

There is a plugin called language-kumachan for the Atom Editor. It is still naive, therefore incorrect highlight could happen.

LICENSE

LGPL-3.0