www.nickhodge.com

microsoft, munging and on being a mercurial iconoclastic professional geek.

Mind Migration: Orcas / Visual Studio 2008 Beta 2 and LOLCODE.net

with 3 comments

aka: I CAN HAS EAT FREEWILLY NOW?

before read­ing this: note I am a scripter at best; and am learn­ing C# and all the Microsoft tools. I know more than I’ve done which means I am super dan­ger­ous. Doing this is purely an exper­i­ment in what is pos­sible, not what really should be done to ensure that the world cools down so whales don’t get eaten by Orcas.

Why LOLCODE.net? Does the world really need another obscure pro­gram­ming language?

Why doesn’t the world have one stand­ard lan­guage. You know, like French or English?

The brain is a strange thing. Lan­guage helps people com­mu­nic­ate ideas, or memes, from one per­son to another.

Pro­gram­ming Lan­guages are more form­al­ised as they map to a very bin­ary com­puter under­neath. No memes here.

Mak­ing a pro­gram­ming lan­guage from a meme is an attempt to bridge the LULZ we have in our head to the mundane art of punch­ing in zeros and ones. Eso­teric pro­gram­ming lan­guages r0x0rz

Enough eso­teric blath­er­ing on lan­guages as noone cares and onto my per­sonal LOLCODE  journey.

http://lolcode.com/ is LOLCODE cent­ral, where the lan­guage is being form­ally spe­cified (more form­ally than Ruby, albeit less func­tional. Pun, get it?)

Orcas. Sort of like a black-and-white cat of the sea that eats seals, but has no paws. Orcas are pretty smart beast­ies. Love eat­ing the tongues of whales. Funny code name for Visual Stu­dio 2008. For this, I’ve installed beta 2.

LOLCode.net. Grab the .zip file from the archive and pop into a dir­ect­ory “c:\program files\lolcode\”

Readme.txt:
This dis­tri­bu­tion includes the com­piler (lolc.exe), com­piler lib­rary (lolcode.net.dll),
stand­ard lib­rary (stdlol.dll) and code samples.

Read the readme. Hmm, accord­ing to the Readme and the LOLCODE forum, “We’d need MSBuild sup­port and a VS exten­sion”. Quick live.com search on msbuild. Ah, msbuild is a build plat­form. Gotcha. Visual Stu­dio exten­tion.  Now that looks harder.

Might just stick to the doc­u­ment­a­tion and use com­mand line. Firstly, let’s stick the dir­ect­ory into my %PATH%

OK, run cmd

type cd c:\Program Files\LOLcode\

Let’s be brace and just lolc fulltest.lol   (that is, com­pile the .lol file fulltext.lol)

Error at line: 2. “Lib­rary ‘STDIO’ not found” (line sez: CAN HAS STDIO?)

Prob­ably best to go from source. I’ve been put­ting this off for months: it’s time for an SVN cli­ent for Win­dows. Off to Tor­toiseSVN so I can down­load a build.

Using Tor­toiseSVN check­out http://lolcode-dot-net.googlecode.com/svn/trunk/ Revi­sion 35 at the time of posting.

Double-click on the .sln file (Visual Stu­dio solu­tion file) and con­vert to VS2008.

Ahh, 51 com­pile errors and 17 warn­ings. Need NUnit. http://nunit.org/ here I come. Installed, and 0 com­pile errors, 11 warn­ings. For­get the warn­ings. If they were ser­i­ous, they’d be errors. Coolio. Set my code to gen­er­ate a Release version.

Again, run cmd

cd C:\Program Files\LOLcode\lolc\bin\Release

lolc test.lol

Suc­cess! I have a test.exe

test

Num­ber guess­ing game. I CAN HAS LOLCODE, com­piled from source.

 

Tech­nor­ati Tags: , ,

Written by Nick Hodge

July 31st, 2007 at 6:27 pm