This repository has been archived by the owner on Aug 30, 2023. It is now read-only.
Syntax Manual v2.0.0 #53
iwl-lyam
announced in
Syntax Guide
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Welcome to the v2.0.0 Syntax Manual! I will run through all valid instructions/syntax in Evaluate.
Functions
Like most programming languages, standard functions can be called using the format:
functionname(parameters)
.Standard Library
printf
As with some other programming languages, printf takes a formatted string and prints it out. It can be formatted using:
Memory
Strings can be defined using quotes
" "
. Single quotes' '
won't work.Variables
Evaluate is aiming to enforce static typing in the future. To start, it requires type annotations upon declaration. The valid types are:
Int_8
Int_16
Int_32
Int_64
Char
String
Bool
The standard format for declaring variables is
<type> <name> = <value>
.Blocks
In this update, blocks have been introduced! These are snippets of code that can have modifiers applied to them, such as
loop
.Block modifiers change how the code in the blocks is compiled. The valid modifiers are:
loop <amount>
The standard format for using blocks is
{ <block code> } [modifier]
Conclusion
It's been a long journey since Equate v1, and I've pulled out all the stops to make everything work. Thanks for supporting the Evaluate project, there's a lot more to come soon so stay tuned!
Beta Was this translation helpful? Give feedback.
All reactions