Welcome to my custom MultiScript(A programming language developed for this project) compiler. It is named this because it will be able to be compiled to many different languages.
Currently, it only has basic features and can only be compiled to Javascript, Python, and C
Implemented Features | Planned Features |
---|---|
|
|
Scroll down to view programming guide
Code
Output
To create a variable called <variable name> do.var <type> <variable name>
To set the value of a variable do.<variable name> = <value>
You also can create and assign a variable at the same timevar <type> <variable name> = <value>
Here are a few examples
//Printing a + b Outputs 10
var int a = 3;
var int b = 7;
println a + b;
//If statement Outputs 12
var int a = 3; var int b = 4;
if (a < b) {
println a*b;
}
Strings
//Printing "Hello World!"
var string message = "Hello World!";
println "Hello World!";
println message;
//Methods also work //Method returns 5
func int add(int a, int b){
return a + b;
}
a(3, 2);
//Python only code
@target("python") println "Hello World!";
//Macros inject code into where they are used
macro example{
println test;
}
var string test = "Hello";
#example