Note that Bite is in heavy development and most of the features have not been yet implemented.
Bite (formerly mini) is a multi-paradigm dynamically typed scripting language made to be fun and easy to use and embed into other applications.
Made to be used in bite-100 fantasy console (soonβ’) but is versatile enough that can be used in other applications as well.
- Easy to embed into c++ applications
- Writen using very modern c++
- Modern and clean syntax
- Fast enough for a scripting language
- Well documented and structured implementation
# lines starting with # are comments
# variables are defined using "let" keyword
let awesomeness = 10; # integers
let bugs = 4.5; # floating point numbers
let review = "best language ever"; # strings
let is_bite_best_language_ever = true; # booleans
let critics = nil; # empty value
# you assign values to variables like u would expect
awesomness = 11;
# you may change change type of variable using assigment
is_bite_best_language_ever = "of course!!!";
# you can use bite as your calculator (all math operations are here)
let amazingness = awesomness * (bugs + 10);
# even bitwise ones
let amazingness_times_two = amazingess << 1;
# if statements are also here
if (bugs < 10) {
bugs = 10;
} else if (bugs > 100) {
amazingness = 10000000;
} else {
critics = "me";
}
# while loops also checking in!
while (amazingness < 100) {
amazingness = amazingness * 2;
}
# and of course functions also came!
fun add(a, b) {
return a + b;
}
review = add(amazingness, awesomness);
- very recent version of c++ compiler (gcc >= 13)
- cmake >= 3.22
git clone https://github.com/upedd/mini.git
cd mini
cmake -S . -B build # Your bite executable is now in build directory
./bite [path to your bite file]
- Robert Nystrom and his Crafting Interpreters