Subject Re: Gpre & Cobol
Author Stephen Boyd
> If you're lucky, the module still be maintainable. Adding some
switched
> to control the dialect should be straightforward. GPRE is designed
> around a single parser with an open ended set of code generators. Most
> languages had a single code generator for all dialects, but PASCAL
> varied so widely that I think we had three different code generators.

cob.cpp doesn't look too bad.

I hadn't thought of creating an entirely new code generator, I was
thinking more in terms of tweaking the existing one to better handle
multiple dialects. Moving some of the keywords from #define to a
table for example.

> I think you could call a plenary session of all Firebird Cobol users,
> elect yourself chairman by acclimation, and go at it.

I rather suspected as much but I thought it would be a good idea to
see if anyone else was masochistic enough to still be using Cobol.

> Are you going to add support for object oriented Cobol, also known as
> "Add One to Cobol"?

Hadn't planned on it. The limited exposure that I have had to OO
Cobol makes me think that if I want to write OO code I will use a
language that was designed for it from the ground up. Declaring a
what would be a 1 line method in C++ takes about 20 lines of OO Cobol
and accessing methods and properties is syntactically torturous.

Having said that, the way OO Cobol works you could probably use GPRE
as it stands (with appropriate fixes) and it would work just fine.
Wouldn't be terribly object oriented but it would work. I think.