Monday 28 September 2009

All code used to be CAPS

Nowadays nearly all code is written in mixed case.
But in the late 70's and early 80's we used dumb screens (3270's) and the ISPF editor would be configured to automatically capitalise just about everything you typed.
So PL/1 programs were written in CAPS.

When we started using Script/DCF (which became GML (leading to HTML then XML)) to develop the system documentation then we typed in mixed case.

I wanted to extract the comments from my code in order to:
a) produce the detailed design
b) provide input for the Data Dictionary
so I wrote a program that was affectionately called ptery.
Note: This was well before we knew about Doxygen.
BUT THE DOCUMENTATION WAS NOT PRETTY
AS IT WAS IN CAPITALS.
SO I STARTED DEVELOPING MY CODE IN Mixed Case.

This was against the programming standards at the time. So the compromise we eventually agreed (Dave Jelley, Steve Smith, Adrian Prince, etc) was that I'd write the code in CAPITALS and the comments in mixed case.

We now make things all capitals (CAPS) if they are global constants, defines or macros.

As an aside, I have never learnt to type with the Caps Lock on.I simply press the shift key with my left ring finger, and make do with 5 or 6 other fingers from both hands to press the keys.

No comments:

Post a Comment