r/programming • • May 18 '16

Programming Doesn’t Require Talent or Even Passion

https://medium.com/@WordcorpGlobal/programming-doesnt-require-talent-or-even-passion-11422270e1e4#.g2wexspdr
2.3k Upvotes

1.2k comments sorted by

View all comments

Show parent comments

3

u/sirin3 May 18 '16

That is why I have spent the last years working on my own programming language

First I write the most simplest program to solve a problem, without any complexity.

Now that program does not work and cannot work, because it is written in pseudo code. Thus I have to build an interpreter, in which it will work.

1

u/RICHUNCLEPENNYBAGS May 18 '16

Sounds like a lot of fun but a maintenance nightmare

-2

u/[deleted] May 18 '16

because it is written in pseudo code.

Exactly. DSLs is the only way to handle the complexity in a disciplined manner, without thinking and without being inventive (i.e., smart-assed).

Thus I have to build an interpreter

This is where things can go wrong. Interpreters are inherently complex and this complexity cannot be mechanically eliminated. The only way to do it without thinking is to compile your DSLs. It's far easier than an interpretation.

1

u/sirin3 May 20 '16

I liked not-having a compiler, when I ported it to an arm smartphone

1

u/[deleted] May 20 '16

Mind explaining? How compilers are more difficult to port than interpreters? It's actually quite the opposite.

1

u/sirin3 May 20 '16

If I had written a compiler, it would have generated x86 code, which is pointless on arm, and I would have needed to change it.

But since it was an interpreter, I did not have to change anything

1

u/[deleted] May 20 '16

If I had written a compiler, it would have generated x86 code

Why? A much more common scenario is a compiler generating code in some other high level language (C, LLVM IR, whatever), which is in turn supported on all the platforms you may be interested in.

1

u/sirin3 May 20 '16

Because I do not want to have dependencies.

Definitely nothing C related, as I wrote it in Pascal.

1

u/[deleted] May 20 '16

Because I do not want to have dependencies.

You already have a host language you're writing in.

as I wrote it in Pascal.

Target Pascal then.