MPGH's C++ Section

Posts 15 of 5 · Page 1 of 1
MPGH's C++ Section
This is basically it:



 
If you want to be disinterested in this thread, click here.

Also, I have finalized my grammar rules for pophicmorly, I am working on a compiler for et right now (/am using antlr to generate lexer\parser\tree-walker) There are some thing I changed in this code to simplify it (in the actual version, you never explicitly specify registers so the compiler can use more advanced reg-swapping methods)

Code:
#attribute[#arg_obstruct = none, #local_obstruct=none, #convention=default]
void myFunction()
{
	#attribute(#cycles=1, #method=random)
	#init()
	{
//YEAH I KNOW I CAN JUST EXTEND THE SCOPE, THIS IS TO DEMONSTRATE A FEATURE THOUGH.
		#rnd = rand(20, 50);
		#a()
		{
			#asm
			{
				sub esp, #rnd
			}
		}
		
		#b()
		{
			#asm
			{
				sub esp, #rnd
				add esp, 13;
			}
		}
	}

	#()
	{
		#(#init::b)
		{
			sub esp, #init::b::code[1]::arg[1]
		}

		//Do some bs here

		add esp, #init::code[0]::arg[1]
	}
}
Like the VB section
This pie chart is 100% accurate.
Yeah pretty much
Great and real
Posts 15 of 5 · Page 1 of 1

Post a Reply

Similar Threads

Tags for this Thread

None

Need help?