Advertising
Implementing arrays and functions?
Implementing arrays and functions?
Hey everybody... I've recently read this article http://msdn.microsoft.com/en-us/magazine/cc136756.aspx and I extended the compiler by adding if statements and more commands... I noticed that there's special IL code for functions with arguments and arrays... Could anybody show me how to implement those in my language?




Re: Implementing arrays and functions?
IL code? Can you please specify more what you mean?
Advertising
I wanna lots of mov al,0xb

"just not into this RA stuffz"

"just not into this RA stuffz"
Re: Implementing arrays and functions?
You probably already know that, but the whole .NET Framework (Languages and Libraries) is translated to IL code before compilation and is then JIT-Compiled. That problem was solved by MONO using AOT-Compilation. I prefer the first method for my language. So, after the code has passed through my lexer and parser I use reflection Libraries to emit IL code that is "interpreted" by the .NET Framework runtime "compiler". I've researched the matter a bit and I found out that there's special IL code for arrays and functions with arguments and fields. I've managed to implement variables but I can't understand how to implement the stuff mentioned before... I've also looked a bit at the source code of Boo but it is too messy.m0skit0 wrote:IL code? Can you please specify more what you mean?




Re: Implementing arrays and functions?
Well I have no idea about .NET to be honest, but that seems a lot like Java. I'm sorry but I can't help further, but this should be very well documented by M$ anyway.
I wanna lots of mov al,0xb

"just not into this RA stuffz"

"just not into this RA stuffz"
Re: Implementing arrays and functions?
.NET is a copy of Java... Just like Windows is a copy of Mac OS..m0skit0 wrote:Well I have no idea about .NET to be honest, but that seems a lot like Java.
Does anybody here know about the .NET? Also, I am thinking of changing it to target a framework of my own... Is this too difficult?




-
devshelper
- Posts: 134
- Joined: Sat Mar 19, 2011 12:09 pm
Re: Implementing arrays and functions?
you wanna make your own framework?
Re: Implementing arrays and functions?
Nope I want what I described in the past posts...devshelper wrote:you wanna make your own framework?




