News: 1647460805

  ARM Give a man a fire and he's warm for a day, but set fire to him and he's warm for the rest of his life (Terry Pratchett, Jingo)

An open-source COBOL contender emerges

(2022/03/16)


The newly announced gcobol compiler is a fresh front end for GCC, and builds native binary executables.

There are already other FOSS and freeware compilers for COBOL out there, but few are fully open source. Notably, there's GnuCOBOL, which evolved out of OpenCOBOL. The OpenCOBOL [1]FAQ is worth a read, and notes that: "OpenCOBOL was initially developed by Keisuke Nishida from experience working on TinyCOBOL originally developed by Rildo Pragana."

There's nothing wrong with GnuCOBOL: it's mature, in active development, and supports various COBOL standards and dialects – but as the [2]announcement for gcobol says: "Our project should not be confused with GnuCOBOL. That project is a Cobol translator: it compiles Cobol to C, and invokes gcc to produce executable code."

[3]

You can still get [4]COBOL-IT for free. This French project developed an open-source compiler suite until it was acquired by "the guardians of business COBOL" – or alternatively, a retirement home for ageing software businesses – aka Micro Focus – in 2017.

Don't put me on the cart

Despite now being [5]over 60 years old , COBOL is very much alive, well, and relevant. The last two standards were [6]COBOL-2002 , which introduced object oriented programming, and [7]COBOL 2014 , which among other things added [8]IEEE-754 floating-point arithmetic handling, method overloading, and dynamic capacity tables.

Over on the commercial side of things, IBM introduced a 64-bit compiler for AIX and later a [9]native x86 one . Micro Focus' Visual COBOL lets you build for .NET and [10]Cloudflare will run it in the cloud.

[11]

[12]

These are still very early days for the new compiler, which has so far seen one man-year of work – which is to say, two programmers have been working on it full-time since October last year, although its Gitlab [13]page shows that work started earlier.

[14]Db2, where are you? Big Blue is oddly reluctant to discuss recent enhancements to its flagship database

[15]Tech bro CEOs claim their crowns because they fix problems. Why shirk the biggest one?

[16]Stack Overflow survey: Microsoft IDEs dominate, GCP and Azure battle behind AWS

[17]IBM creates a COBOL compiler – for Linux on x86

So far, as a validation suite, they are working through the example programs from the 2014 [18]book Beginning COBOL for Programmers , and gcobol successfully compiles a hundred of them. If you're curious, the programs are on [19]GitHub . After this, the developers plan to move on to the NIST COBOL-85 test [20]suite . ®

Bootnote

Yes, new books about learning COBOL are being published. There's considerable demand for COBOL programmers – ever since the Y2K problem, old hands have been coming out of retirement, at premium rates of course. Now they're dying off, and increasingly desperate COBOL users [21]were previously appealing for volunteers to help. If you can wrap your head around this relatively simple but verbose language, you are basically guaranteed a job.

Get our [22]Tech Resources



[1] http://opencobol.add1tocobol.com/

[2] https://gcc.gnu.org/pipermail/gcc/2022-March/238408.html

[3] https://pubads.g.doubleclick.net/gampad/jump?co=1&iu=/6978/reg_software/front&sz=300x50%7C300x100%7C300x250%7C300x251%7C300x252%7C300x600%7C300x601&tile=2&c=2YjJsI1@88h-Gf6HWcnMqWwAAAAY&t=ct%3Dns%26unitnum%3D2%26raptor%3Dcondor%26pos%3Dtop%26test%3D0

[4] https://www.cobol-it.com/

[5] https://www.theregister.com/2019/09/16/cobol_at_60/

[6] https://www.iso.org/standard/28805.html

[7] https://www.iso.org/standard/51416.html

[8] https://standards.ieee.org/ieee/754/6210/

[9] https://www.theregister.com/2021/04/07/ibm_cobol_x86_linux/

[10] https://www.theregister.com/2020/04/16/cloudflare_cobol/

[11] https://pubads.g.doubleclick.net/gampad/jump?co=1&iu=/6978/reg_software/front&sz=300x50%7C300x100%7C300x250%7C300x251%7C300x252%7C300x600%7C300x601&tile=4&c=44YjJsI1@88h-Gf6HWcnMqWwAAAAY&t=ct%3Dns%26unitnum%3D4%26raptor%3Dfalcon%26pos%3Dmid%26test%3D0

[12] https://pubads.g.doubleclick.net/gampad/jump?co=1&iu=/6978/reg_software/front&sz=300x50%7C300x100%7C300x250%7C300x251%7C300x252%7C300x600%7C300x601&tile=3&c=33YjJsI1@88h-Gf6HWcnMqWwAAAAY&t=ct%3Dns%26unitnum%3D3%26raptor%3Deagle%26pos%3Dmid%26test%3D0

[13] https://git.symas.net/cobolworx/gcc-cobol/

[14] https://www.theregister.com/2021/12/23/db2_where_are_you/

[15] https://www.theregister.com/2021/11/15/tech_must_help_save_planet/

[16] https://www.theregister.com/2021/08/03/stackoverflow_developer_survey/

[17] https://www.theregister.com/2021/04/07/ibm_cobol_x86_linux/

[18] https://link.springer.com/book/10.1007/978-1-4302-6254-1

[19] https://github.com/Apress/beg-cobol-for-programmers

[20] https://www.itl.nist.gov/div897/ctg/cobol_form.htm

[21] https://www.theregister.com/2020/04/05/new_jersey_cobol_volunteers_mainframes/

[22] https://whitepapers.theregister.com/



Paul Herber

So, now we all know the Blondie song written in Object Cobol:

This.picture my telephone number

Get a pocket computer

What I'm telling you is one and one

Stop (FFS stop)

b0llchit

General exception: False note detected before Stop. Picture cannot be converted into telephone to produce sound at runtime. Reason: computer did not fit pocket.

Core dumped.

Paul Herber

A well-known computer centre used to often run out of toilet paper and old cobol dump printouts were put in a bin to be used in such emergencies - hence the phrase - take a dump.

And not many people know that.

HildyJ

As one of a dying breed who has seen core dumps, and can read core dumps, your computer center personnel are idiots. Chain drive printer paper is tough, non absorbent, and would excel only in ripping you a new arsehole.

Much better to use old phonebooks.

Jim Mitchell

I learned today that Trump was a COBOL programmer.

"COBOL-2002, which introduced object oriented programming"

Gene Cash

"Object oriented COBOL"

Now there's a phrase I never though I would hear, outside of a joke.

So when will we have object oriented FORTRAN? I should probably shut my mouth...

Re: "COBOL-2002, which introduced object oriented programming"

Paul Herber

Ancient history.

Re: "COBOL-2002, which introduced object oriented programming"

chololennon

"So when will we have object oriented FORTRAN?"

We already have it: https://en.wikipedia.org/wiki/Fortran#Fortran_2003

Christoph

" Now they're dying off, and increasingly desperate COBOL users were previously appealing for volunteers to help. "

So we need a load of old Cobolers?

Where it is a duty to worship the sun it is pretty sure to be a crime to
examine the laws of heat.
-- Christopher Morley