DEV Community

Thomas Leathers
Thomas Leathers

Posted on

Have you ever designed your own language?

Top comments (2)

Collapse
 
ohffs profile image
ohffs

Before I had a computer (back into 1970's) I would write 'programs' in a paper notebook in a language I had made up based on a programming book I found in the local library (ah, the olden days).

Then in the late 80's/early 90's I made an actual language & compiler that was a kind of 'BASIC meets PASCAL'. It had some nice features for games programmers - but sadly the platform I was on at the time (Atari) disappeared from under me so I never really developed it beyond the initial compiler and prototypes.

It's main selling point was (was going to be!) that it could spot patterns in blocks of code, and swap them out with more efficient ones if it could. So you could have a library of your own custom hand-written ASM animation routines or whatever and if the compiler saw you were 'move all the sprites to the left' it would swap in your custom ASM code.

Oh, to be that young and enthusiastic again ;-)

Collapse
 
thomasthespacefox profile image
Thomas Leathers • Edited

I have designed a few smaller script languages for some project-specific tasks. such as:

  1. Desutezeoid Animation script (DZA) A fairly basic animation & sequencing script for my point and click adventure engine, Desutezeoid, intended as a compliment to its main, XML-based, 'rule-based' logic.

  2. eXtensible Assembler Script (XAS) A simple build script/development shell system for SBTCVM, a base 3 virtual computer i designed.

Ive also designed a few more serous languages. Both of which for SBTCVM.

  1. SBTCVM Assembly: A fairly advanced listing-style (1 keyword = 1 cpu operation) assembly language.

  2. SSTNPL (SBTCVM Simplified Ternary Numeric Programming Language): a math-centric language with named integers, 2D arrays (called tables), iterators, and a goto/label structure with separate stack-based subroutine gotos & returns. I even did a tutorial series for SSTNPL on dev.to