After many more hours hammering out code I've added some new functionality to my compiler and given it a new name!
Just as a recap Mocha is a Basic > FASM compiler which I've writeen from scratch, it supports:
Operators
Code: Select all
+ - * / ( ) / ^
Variables
Code: Select all
Long.l
Float.f
String.s
Code: Select all
#Number=1
#String="constant"
Code: Select all
Structure Test
{
Long.l
Float.f
String.s
}
MyVariable.Test
MyVariable\Long=1
Code: Select all
Enumeration
{
#Constant1
#Constant2
#Constant3
}
Code: Select all
ASM
{
Mov eax,1
;Essentially this code block is ignored by the compiler - so no error checking is performed
}
A small note on brace syntax. The following are all ok (using Enumeration as an example, but applicable to all):
Code: Select all
Enumeration {
#Constant
}
Enumeration
{
#Constant2
}
Enumeration{
#Constant3
}
Enumeration
{
#Constant4 }
Enjoy!
DOWNLOAD