Skinned Programming Paradigms

Here’s a free thought for you.

How much of people choice in programming languages is really syntax dependent?

For example, I dislike Java (I hate it for other reasons) simply because of the verbosity of ‘System.out.println’ and don’t really understand why Scala would chose ‘println’ instead of Python’s terse use of ‘print’.

And I’m pretty sure despite overt rationalizations like ‘saving myself keystrokes’ that’s just a petty reason.

However, what I learned in compiler construction is that the parser or tokenizer is really separate from the language itself.

So, for example, there’s no reason there couldn’t be a plugin for Java that allowed me to write with python’s syntax, or vice versa. Such a technique might require a little bit of library support, but I suspect adding pythons ‘map()’ even to C/C++ would be fairly trivial.

We should be able to ‘skin’ our languages with our syntax of choice regardless of the underlying compiler, JVM or bytecode.

If this were possible, then ‘language wars’ could be less about syntax and interface (a la emacs vs. vi) and more about the underlying value of the language itself.

If we can theme operating systems and user interfaces, then why not programming languages?

About jay

I'm trying to build something interactive where I can learn from others and hopefully share useful knowledge too. thecapacity@gmail.com
This entry was posted in code, frustration, inspiration. Bookmark the permalink.

5 Responses to Skinned Programming Paradigms

  1. Pingback: bharatinfo.com

  2. Pingback: pligg.com

  3. Pingback: zabij.com

  4. Kevin Tambascio says:

    Actually, something similar to what you’re describing is available in .NET…they designed it so that many languages can all plug in to the front-end, produce language-neutral bytecode to run on the back-end. There’s a big list of languages that can now run under .NET, including Ruby and Python.

    Why so much hate for Java? I’m pretty impressed with the productivity gain my team is getting from it, over C++.

    • jay says:

      Well,
      I admit most of hate for Java is exaggerated but there are a few main reasons.

      (1) I hate it’s verbosity (System.out.println or all the syntax required)
      (2) I don’t think a good language should ‘require’ so much tool support to be manageable
      (3) I hate that they’ve basically reinvented everything (hello ‘ant’, meet ‘make’ … he’s your father).
      (4) I feel like they basically spend a lot of time rebuilding C/C++ and didn’t really advance things beyond the JRE
      (5) I dislike that it was such a proprietary language for so long
      (6) I’m positive my biggest dislike for it was that as a system tester, when it went south I could only throw my hands up and say “you have a problem in your software, but all I can tell you is the JRE is going nuts… have fun”.

      I’d heard that .NET supported languages like python, ruby, etc. But all the Azure stuff I’ve seen basically makes it sound like that support is that the .NET API’s are REST, etc.

      So it would be interesting to me to see if you could write in whatever syntax you wanted but it compiled into the same interpreter.

      Clojure and Scala seem neat to me because they compile into the Java JRE (which I know I just admitted to disliking) but they’re still fundamentally two separate languages.

Comments are closed.