Working name: Hob

Working name: Hob

Why exactly are high-level programming languages so fascinating?
Myself, I started as a dedicated C++ programmer. I found a stimulating
challenge in knowing all the obscurities of that language, and writing
reasonably maintainable code in it. But then, some five years ago, I
found myself exposed to both Scheme and Python. It was a feeling as if
a new world suddenly opened. Python allowed me to write programs that
would take days in C++ in an hour or so, allowed me to use complicated
techniques that were guaranteed to leave me stranded in
memory-management problems or pointer bugs when I attempted them in
C++. Scheme, then, showed me that a language can be elegant and
internally consistent, and taught me functional programming.

Having discovered these brave new worlds, I concluded that language
matters. A well-designed high-level language produces shorter,
clearer, more beautiful programs. This is where the fascination comes
from. I went down the road of the typical PLT nerd, implementing my
own Scheme interpreter,
learning as many new languages as I could, smugly looking down on
mainstream languages, and daydreaming about the way I would design
a language.

Now here we are. I have read plenty of programming-language theory
papers, got to the point where I feel I understand most of the
interesting ideas in language design, and day-dreamt a lot. I guess I
might as well do something with all that knowledge, and to build that
brilliant, world-changing new programming language.

Well, I haven’t really got such illusions of grandeur. My plan is more
modest: Design and implement a toy language, make a lot of stupid
mistakes, write about the process, have fun, and learn something.

For now, I’m naming this language
Hob, after obscure mischievous
spirits in Germanic and Anglo-Saxon folklore. It’s a nice short,
memorable name, and a programming language can seem temperamental or
mysterious at times.

My major inspirations are Haskell, O’Caml, and Lisp. The language (as
it lives in my imagination now) will be elegant like Haskell, but
strict and non-pure. Practical and efficient like O’Caml, but with
type classes and a proper concurrency model. Flexible and interactive
like Common Lisp, but with static typing and a comprehensible
compilation model.

Syntactically, it’ll mostly resemble Haskell. I have a vague notion of
how to making Lisp-ish macros pleasant to work with in a less regular
language, but more about that when I’ve worked it out properly.
Modules and immutable data will be at the core of the language’s
design, with first-class modules if I manage to formalise some elegant
and implementable semantics for them.

The first implementation of Hob will be in Common Lisp, with a
self-hosting version down the line. Right here on these pages, I’ll
describe the process of implementing it. The writing will typically
not go down into grubby coding details, but discuss design issues and
general implementation techniques. The whole process will take a
while, and of course I can not really guarantee that I won’t drop out
before getting anything serious working. But I’m giving it a shot.

Anything written down about the language in these pages holds at the
moment I write it
, but might be completely overhauled later on. There
is a repository with the code on this
, which always
holds the current state of the implementation.

Comments are closed.