2006-04-17 14:55

The missing language

In the last month or two I have been writing a fair bit of C code.

I really dislike C. But I have not been able to find a language to replace it with, except C++, and that's not much of an improvement for what I did.

Maybe someone can read this and help me. I don't mind learning a new language. Really, it's no problem.

The goal is writing small programs (in the hundreds of lines region), which have the following requirements:

  1. The program MUST be correct. Can never segfault or crash in some other way.

Since the code is short, I think I have managed, using bstrlib, to get this, after quite a bit of pain, by auditing and unit-testing. But I am not sure, and I will never be.

It would be awesome if the language could be garbage-collected for this reason.

  1. It MUST have a decent string handling.

The programs handle mail. So, it's strings galore.

  1. It MUST have very low overhead. The programs should run and end quickly. Very quickly, because people may be waiting for them to end.
  2. It MUST be a reasonably simple language. I am not a great programmer, and these tools will be hacked at by people with limited programming skills (sysadmins like me!)
  3. Trivial access to C libraries.

So, let's see.

C: gives 3, 4 (in a fashion), and 5

C++: 2, 3, maybe 4, and 5

D: It seems to give me all of these, along with a C-like syntax... but I can't get it to work yet (correction, I got dmd to work, so it's looking good for D!).

So, any takers?

Comments

Comments powered by Disqus

Contents © 2000-2019 Roberto Alsina