archives

Designing a Type Notation for a Stack Based Functional Language

I am designing a dialect of Joy called 'Big Cat'. Like Joy, Big Cat is a pure stack based functional language (or concatenative language, if you like the term). This means that every function takes a single stack as a parameter, and returns a new stack as a result. Most programs expect a certain stack configuration, so I am devising a syntax for expressing the desired type configuration.

One of the changes is the introducction of a type notation for operations. Here is my current proposal:

  swap (T, U) => (U, T);
  dup (T) => (T, T);
  dupN (int, T) => (T*);
  pop (T) => ();
  popN (int, T*) => ();  
  if (() => T, () => U, bool) => (U|T);

I welcome feedback, and suggestions. Let me know if the syntax is not intuitive and you need clarification, thanks!

APL Quote Quad Call for Papers

The ACM Special Interest Group for Array Programming Languages is expanding it's scope beyone classic APL. Papers on Lush implementation or array oriented applications would be appropreate.

ANNOUNCEMENT

Issue 34:3 of APL QUOTE QUAD is now closed and ready for publishing.
We are now starting to process the next issue (34:4), and we need new
material. Therefore, I am sending this

CALL FOR PAPERS

APL QUOTE QUAD

The next issue of APL Quote Quad is being designed. Prospective authors
are encouraged to submit papers on any of the usual subjects of
interest related to Array-Processing Languages (APL, APL2, J,
and so forth).

Submitted papers, in Microsoft Word (.doc), Rich Text Format (.rtf),
Openoffice format (.scw), Latex (.tex) or Acrobat (.pdf)
should be addressed to

Manuel Alfonseca
Manuel.Alfonseca@ii.uam.es

Care must be taken to make the submitted papers self-contained,
eg. if they require special APL typesettings.

The tentative time limit for the new material is May 31st, 2006.