Angel \”Java\” Lopez on Blog

April 27, 2009

Presenting AjCat

Filed under: .NET, C Sharp, Programming Languages — ajlopez @ 9:16 am

Some weeks ago, I was working on an interpreter of the Cat language:

The Cat Programming Language

Cat is a functional stack-based programming language inspired by the Joy programming language. The primary differences is that Cat provides a static type system with type inferencing (like ML or Haskell), and a term rewriting macro language extension language called MetaCat.

Cat is a high-level intermediate language translation that can also be used as a stand alone language for simple application development. In this way it occupies a similar niche to PostScript. Cat is also an appropriate language for teaching of basic programming concepts.

If you are not familiar with Cat language, you can learn more at:

Cat Tutorial
Cat Specification
Cat Primitives

I published the code as part of my Code Katas Google code project. It’s named AjCat:

http://code.google.com/p/ajcodekatas/source/browse/#svn/trunk/AjCat

The solution contains three projects:

The implementation is not complete. It’s only support integers, no .NET object support yet, and no graphics primitives.

Running the console program, you can enter and evaluate expressions:

This code is dedicated to Rodolfo Finocchieti (@rodolfof in Twitter) who pointed me to Cat language, a fascinanting idea.

Tests are green:

And good code coverage

Angel “Java” Lopez
http://www.ajlopez.com/
http://twitter.com/ajlopez

1 Comment »

  1. Thanks!!!!!

    Your Cat implementation is great!

    Comment by Rodolfo Finochietti — April 27, 2009 @ 8:11 pm


RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Blog at WordPress.com.

%d bloggers like this: