[MUD-Dev] Mud Languages

clawrenc at cup.hp.com clawrenc at cup.hp.com
Wed Aug 13 16:14:49 New Zealand Standard Time 1997


In <Pine.LNX.3.91.970806171649.7562V-100000 at uni-corn.demon.co.uk>, on
08/06/97 
   at 07:57 PM, Greg Munt <greg at uni-corn.demon.co.uk> said:

>I'm thinking that designing a language blindly would be a Bad Thing. 
>Since subscribers to this list would probably have wide-reaching 
>experiences in many languages, I'd be interested in, say, a list of
>the  top five best and worst features of a language (features
>specific to a  certain language, in addition to generic attributes).

Unfortunately a good answer to this question would require several
walls of encyclopedia sized books (you could start with the infamous
dragon book).  I'm also not that interested.

My approach steals a lot from Mike Cowlishaw's own design goals with
REXX (I think you can still find them listed on his home page): Keep
it very simple, and obvious for new non-programmer types.  This mostly
resulted in making the language typeless, having no concept of
pointers to data or pointers to methods, having a very small set of
reserved words, and trying to concentrate on doing basic common
operations easily.

I also want my language to be at least somewhat friendly to
programmers.  This leads to taking the same general view taht ColdC
does, and using something C-like.

As a result my language is almost identical to C with the following
exceptions:

  Variables may be "temporary", which means that their values will not
be preserved across method/object invocations, or "permanent" which
means that their value will be preserved.

  Variables are scoped to the block they are defined in.

  Variables may not be defined at a global (game or object) scope.

  No pointers.

  No concept of memory allocation or memory handling.

  No concept of file IO (there are minor exceptions).

  Typeless.

  Code blocking is via { and } braces.

  Code syntax is largely identical to C.

  White space insensitive.

  Semi-colons are only required between statements on the same 
 line (ie white space sensitive)

  Implicit types enclude:  
    integer (currently 32bit, soon 64bit), 
    IEEE float, 
    length limited 8bit string,
    time in seconds,
    ObjectID,
    exception ID
    
  All functions/methods have a return value.

  Explicit list support (ie any variable can be a list of values, 
  and each value in turn can be another list).

  Very simple/fast support for searching lists.

  All functions/methods return exceptions every time they return.  

  A normal return is merely an exception that doesn't require 
  a special handler (ie ERR_OKAY is not trapped, and requires no 
  handler, all other exceptions are processed as critical stack 
  unwinding exceptions.

  A function/method return consists of an exception and a 
  typeless value.

Big positive influences: C, Cool and Interlude (tho I hate Interlude's
LISP underpinnings), ksh, APL.

Big negative influences: C (good and bad), Cold/ColdC, MOO, Tiny-*,
LPC, Pike, Forth, Pascal, C++, APL (yep, both sides). ML/SML, lisp.

--
J C Lawrence                           Internet: claw at null.net
(Contractor)                           Internet: coder at ibm.net
---------------(*)               Internet: clawrenc at cup.hp.com
...Honorary Member Clan McFUD -- Teamer's Avenging Monolith...




More information about the MUD-Dev mailing list