1. 13
  1.  

  2. 6

    I can’’t imagine how well this works outside of the GNU COBOL sample code bubble. Mainframes are around not just because of COBOL, but because of a whole ecosystem of things like Db2 and CICS. (CICS might be interesting to map to the BEAM model though..)

    1. 4

      An aging programming language known as COBOL underpins much of the U.S. financial industry, but it has fallen out of favor among coders. This sets up a problem when systems run into glitches or need updates, and companies no longer have COBOL experts on hand.

      This quote they used bothers me. Saying that it has “fallen out of favor among coders” makes it seem like it’s a reasonable choice for a new project today. It’s just not fashionable. It feels like it’s part of a pattern labeling developers childish or flippant. Imagine if the quote was about weavers:

      An aging type of loom known as a hand loom underpins much of the U.S. textile industry, but it has fallen out of favor among weavers. This sets up a problem when systems run into glitches or need updates, and companies no longer have hand loom experts on hand.

      Obviously, this complaint has nothing to do with the project. It’s cool that they are trying to bring down barriers to change and I hope they are successful translating projects to Elixir. (Though an automatically translated 50 year old banking system sounds like it would be a terrifying code base to work in.)

      1. 3

        I find the COBOL code on the site much more readable than the mess of brackets that is Elixir.

        1. 2

          Do you mean the 4 curly braces in 20 lines of code? The translated code looks fine to me. Would have a lot more braces if it had C based syntax.

          1. 2

            In general, the thing I like most with COBOL is the (relative) lack of special characters. Sure, it could be worse.

          2. 2

            I did have the same thought. I had never actually seen COBOL before this article. It has a very SQL look to it, which is nice and clean. The contrast between the clean COBOL and the typical bracket-y language syntax is very stark.

            1. 2

              Readability was never one of the common criticisms of COBOL. Quite the reverse: it’s mainly criticised for being verbose. There was a joke that there would be an OO extension to COBOL, just as C++ was to C, called ADD ONE TO COBOL RETURNING COBOL. COBOL, by design, doesn’t have a lot of the syntactic sugar that other languages provide that make things more terse and so is very easy to read but more effort to write (though probably less so with a modern editor that can do a lot of autocompletion).

            2. 1

              Elixir accepts pull requests; perhaps you should work up a patch to banish tuple and map syntax to instead live under DATA DIVISION.

              1. 1

                I doubt they’d accept it.

            3. 2

              Interesting. COBOL’s string concatenation looks like it would be a better fit for Elixir’s iolists, e.g. IO.puts(["Hello ", var_Name]).